VirtualBox

Changeset 103505 in vbox for trunk


Ignore:
Timestamp:
Feb 21, 2024 7:25:15 PM (14 months ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
161848
Message:

libs/xpcom: Fix some unused variable warnings, bugref:3409

Location:
trunk/src/libs/xpcom18a4
Files:
15 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/libs/xpcom18a4/ipc/ipcd/client/src/ipcdclient.cpp

    r103489 r103505  
    11461146            NS_ASSERTION(obs, "must at least have a default observer");
    11471147
    1148             nsresult rv = obs->OnMessageAvailable(pClientState->u32ClientId, nsID(), 0, 1);
     1148            /*nsresult rv = */obs->OnMessageAvailable(pClientState->u32ClientId, nsID(), 0, 1);
    11491149            /* VBoxSVC/VBoxXPCOMIPCD auto-start can cause that a client up
    11501150             * message arrives while we're already waiting for a response
  • trunk/src/libs/xpcom18a4/ipc/ipcd/extensions/dconnect/src/ipcDConnectService.cpp

    r103488 r103505  
    32673267    return NS_ERROR_NOT_INITIALIZED;
    32683268
     3269#ifdef LOG_ENABLED
    32693270  const DConnectOp *op = (const DConnectOp *) aData;
    3270 
    32713271  Log (("ipcDConnectService::OnMessageAvailable: "
    32723272        "senderID=%d, opcode_major=%d, index=%d\n",
    32733273        aSenderID, op->opcode_major, op->request_index));
     3274#endif
    32743275
    32753276  void *pvDataDup = RTMemDup(aData, aDataLen);
  • trunk/src/libs/xpcom18a4/python/src/ErrorUtils.cpp

    r103176 r103505  
    8080static const char *LOGGER_WARNING = "warning";
    8181static const char *LOGGER_ERROR = "error";
     82#ifdef DEBUG
    8283static const char *LOGGER_DEBUG = "debug";
     84#endif
    8385
    8486// Our "normal" error logger - calls back to the logging module.
  • trunk/src/libs/xpcom18a4/python/src/VariantUtils.cpp

    r103176 r103505  
    20152015                PRUint8 array_type = (PRUint8)PyInt_AsLong(td.extra);
    20162016                PRUint32 seq_size = GetSizeIs(index, PR_FALSE);
    2017                 nsXPTCVariant &ns_viid = m_var_array[td.argnum];
    2018                 nsIID iid;
    2019                 nsresult res = GetArrayElementIID(m_parent,
    2020                                                   m_var_array,
    2021                                                   m_methodindex,
    2022                                                   index,
    2023                                                   &iid);
     2017    nsIID iid;
     2018    nsresult res = GetArrayElementIID(m_parent,
     2019                                      m_var_array,
     2020                                      m_methodindex,
     2021                                      index,
     2022                                      &iid);
    20242023                ret = UnpackSingleArray(m_parent, * ((void **)ns_v.ptr),
    20252024                                        seq_size, array_type&XPT_TDP_TAGMASK,
  • trunk/src/libs/xpcom18a4/vboxdeps.cpp

    r102458 r103505  
    5656    nsVoidHashSetSuper *a = new nsVoidHashSetSuper();
    5757    a->Init(123);
    58     nsDeque *b = new nsDeque();
     58    nsDeque *b = new nsDeque(); RT_NOREF(b);
    5959
    6060    //nsXPTCStubBase
  • trunk/src/libs/xpcom18a4/xpcom/base/nsExceptionService.cpp

    r102235 r103505  
    184184  /* member initializers and constructor code */
    185185  if (tlsIndex == NIL_RTTLS) {
     186    /* Parfait_ALLOW unused-var Used for debug builds in the assertion below. */
    186187    int vrc = RTTlsAllocEx( &tlsIndex, ThreadDestruct );
    187     NS_WARN_IF_FALSE(RT_SUCCESS(vrc), "ScriptErrorService could not allocate TLS storage.");
     188    NS_WARN_IF_FALSE(RT_SUCCESS(vrc), "ScriptErrorService could not allocate TLS storage."); RT_NOREF(vrc);
    188189  }
    189190  int vrc = RTSemFastMutexCreate(&lock);
    190   NS_WARN_IF_FALSE(RT_SUCCESS(vrc), "Error allocating ExceptionService lock");
     191  NS_WARN_IF_FALSE(RT_SUCCESS(vrc), "Error allocating ExceptionService lock"); RT_NOREF(vrc);
    191192
    192193  // observe XPCOM shutdown.
  • trunk/src/libs/xpcom18a4/xpcom/components/nsComponentManager.cpp

    r102506 r103505  
    27302730    // Normalize proid and classname
    27312731    const char *contractID = (aContractID && *aContractID) ? aContractID : nsnull;
    2732     const char *className = (aClassName && *aClassName) ? aClassName : nsnull;
    27332732#ifdef LOG_ENABLED
    27342733    char *buf = aClass.ToString();
  • trunk/src/libs/xpcom18a4/xpcom/string/src/nsStringObsolete.cpp

    r102458 r103505  
    12061206    r64.rd = aFloat;
    12071207    ssize_t cch = RTStrFormatR64(buf, sizeof(buf), &r64, 0, 6 /*cchPrecision*/, 0 /*fFlags*/);
    1208     Assert(cch > 0);
     1208    Assert(cch > 0); RT_NOREF(cch);
    12091209    Append(buf);
    12101210  }
     
    12171217    r64.rd = aFloat;
    12181218    ssize_t cch = RTStrFormatR64(buf, sizeof(buf), &r64, 0, 6 /*cchPrecision*/, 0 /*fFlags*/);
    1219     Assert(cch > 0);
     1219    Assert(cch > 0); RT_NOREF(cch);
    12201220    AppendWithConversion(buf);
    12211221  }
  • trunk/src/libs/xpcom18a4/xpcom/tests/TestArray.cpp

    r103140 r103505  
    3737 * ***** END LICENSE BLOCK ***** */
    3838
     39#include <iprt/cdefs.h>
     40
    3941#include <stdio.h>
    4042#include <stdlib.h>
     
    109111  PRUint32 cnt = 0;
    110112  nsresult rv = aArray->Count(&cnt);
    111   NS_ASSERTION(NS_SUCCEEDED(rv), "Count failed");
     113  NS_ASSERTION(NS_SUCCEEDED(rv), "Count failed"); RT_NOREF(rv);
    112114  PRInt32 count = cnt;
    113115  PRInt32 index;
  • trunk/src/libs/xpcom18a4/xpcom/tests/TestCRT.cpp

    r103458 r103505  
    6161static void Check(const char* s1, const char* s2, PRIntn n)
    6262{
     63  /** @todo r=aeichner This test is pretty useless with release builds but do we really care? */
     64#ifdef DEBUG
    6365  PRIntn clib = RTStrCmp(s1, s2);
    6466  PRIntn clib_n = RTStrNCmp(s1, s2, n);
     
    7274  PRIntn u2 = nsCRT::strcmp(us1, us2);
    7375  PRIntn u2_n = nsCRT::strncmp(us1, us2, n);
     76#endif
    7477
    7578  NS_ASSERTION(sign(clib) == sign(u2), "strcmp");
  • trunk/src/libs/xpcom18a4/xpcom/threads/nsAutoLock.cpp

    r101914 r103505  
    5858{
    5959    PRStatus status = PR_ExitMonitor(mMonitor);
    60     AssertMsg(status == PR_SUCCESS, ("PR_ExitMonitor failed"));
     60    AssertMsg(status == PR_SUCCESS, ("PR_ExitMonitor failed")); RT_NOREF(status);
    6161    mLockCount -= 1;
    6262}
  • trunk/src/libs/xpcom18a4/xpcom/typelib/xpidl/xpidl.c

    r103503 r103505  
    136136             * and string variables.
    137137             */
    138             const gchar* typelib_version_string = NULL;
    139138
    140139            /*
  • trunk/src/libs/xpcom18a4/xpcom/typelib/xpidl/xpidl_typelib.c

    r28970 r103505  
    11541154{
    11551155    struct _IDL_CONST_DCL *dcl = &IDL_CONST_DCL(state->tree);
    1156     const char *name = IDL_IDENT(dcl->ident).str;
    11571156    gboolean is_long;
    11581157    gboolean sign;
  • trunk/src/libs/xpcom18a4/xpcom/typelib/xpidl/xpidl_util.c

    r62449 r103505  
    408408                      ParamAttrType whattocheck)
    409409{
    410     const char *method_name = IDL_IDENT(IDL_OP_DCL(method_tree).ident).str;
    411410    const char *referred_name = NULL;
    412     IDL_tree param_type = IDL_PARAM_DCL(param).param_type_spec;
    413411    IDL_tree simple_decl = IDL_PARAM_DCL(param).simple_declarator;
    414     const char *param_name = IDL_IDENT(simple_decl).str;
    415412    const char *attr_name;
    416413    const char *needed_type;
  • trunk/src/libs/xpcom18a4/xpcom/typelib/xpt/src/xpt_struct.c

    r62325 r103505  
    241241XPT_DoHeader(XPTArena *arena, XPTCursor *cursor, XPTHeader **headerp)
    242242{
    243     const int HEADER_SIZE = 24;
    244243    XPTMode mode = cursor->state->mode;
    245244    XPTHeader * header;
Note: See TracChangeset for help on using the changeset viewer.

© 2025 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette