VirtualBox

Ignore:
Timestamp:
Oct 24, 2011 1:58:22 PM (13 years ago)
Author:
vboxsync
Message:

More parameter warning fixes; made PciIch9 check the saved state version.

Location:
trunk/src/VBox/HostDrivers/Support
Files:
6 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/HostDrivers/Support/SUPLibSem.cpp

    r33167 r39091  
    5252DECLINLINE(int) supSemOp2(PSUPDRVSESSION pSession, uint32_t uType, uintptr_t hSem, uint32_t uOp, uint64_t u64Arg)
    5353{
     54    NOREF(pSession);
    5455    SUPSEMOP2 Req;
    5556    Req.Hdr.u32Cookie           = g_u32Cookie;
     
    8687DECLINLINE(int) supSemOp3(PSUPDRVSESSION pSession, uint32_t uType, uintptr_t hSem, uint32_t uOp, PSUPSEMOP3 pReq)
    8788{
     89    NOREF(pSession);
    8890    pReq->Hdr.u32Cookie           = g_u32Cookie;
    8991    pReq->Hdr.u32SessionCookie    = g_u32SessionCookie;
  • trunk/src/VBox/HostDrivers/Support/SUPR3HardenedIPRT.cpp

    r28800 r39091  
    101101    AssertFatalMsgFailed(("%s (rc=%Rrc): %N", pszWhere, rc, pszMsgFmt, &vaCopy));
    102102    va_end(vaCopy);
     103    NOREF(enmWhat);
    103104}
    104105
  • trunk/src/VBox/HostDrivers/Support/SUPR3HardenedVerify.cpp

    r39086 r39091  
    814814}
    815815
     816#ifdef SOME_UNUSED_FUNCTION
    816817
    817818/**
     
    844845}
    845846
     847#endif /* SOME_UNUSED_FUNCTION */
    846848
    847849/**
     
    11881190           full access. So, to work around we relax the hardening a bit and
    11891191           permit grand parents and beyond to be group writable by admin. */
    1190         if (!fRelaxed || pFsObjState->Stat.st_gid != 80 /*admin*/) /** @todo dynamically resolve the admin group? */
     1192        bool fBad = !fRelaxed || pFsObjState->Stat.st_gid != 80 /*admin*/; /** @todo dynamically resolve the admin group? */
     1193
    11911194#elif defined(RT_OS_FREEBSD)
    11921195        /* HACK ALERT: PC-BSD 9 has group-writable application directory,
     
    11971200         *        details would be greatly appreciated as this HACK affects real FreeBSD
    11981201         *        as well as the PC-BSD fork! */
    1199         if (pFsObjState->Stat.st_gid != 5 /*operator*/)
     1202        bool fBad = pFsObjState->Stat.st_gid != 5 /*operator*/;
     1203        NOREF(fRelaxed);
     1204#else
     1205        NOREF(fRelaxed);
     1206        bool fBad = true;
    12001207#endif
     1208        if (fBad)
    12011209            return supR3HardenedSetError3(VERR_SUPLIB_WRITE_NON_SYS_GROUP, pErrInfo,
    12021210                                          "The group is not a system group and it has write access to '", pszPath, "'");
     
    12171225    return VINF_SUCCESS;
    12181226#endif
    1219 
    12201227}
    12211228
  • trunk/src/VBox/HostDrivers/Support/linux/SUPLib-linux.cpp

    r37596 r39091  
    173173{
    174174    AssertMsg(pThis->hDevice != (intptr_t)NIL_RTFILE, ("SUPLIB not initiated successfully!\n"));
     175    NOREF(cbReq);
    175176
    176177    /*
     
    245246int suplibOsPageFree(PSUPLIBDATA pThis, void *pvPages, size_t cPages)
    246247{
     248    NOREF(pThis);
    247249    munmap(pvPages, cPages << PAGE_SHIFT);
    248250    return VINF_SUCCESS;
  • trunk/src/VBox/HostDrivers/Support/testcase/SUPInstall.cpp

    r38636 r39091  
    55
    66/*
    7  * Copyright (C) 2006-2007 Oracle Corporation
     7 * Copyright (C) 2006-2011 Oracle Corporation
    88 *
    99 * This file is part of VirtualBox Open Source Edition (OSE), as
     
    3232#include <VBox/err.h>
    3333#include <iprt/initterm.h>
    34 #include <iprt/stream.h>
     34#include <iprt/message.h>
    3535
    3636
     
    3838{
    3939    RTR3InitExeNoArguments(0);
     40    if (argc != 1)
     41        return RTMsgErrorExit(RTEXITCODE_SYNTAX, "This utility takes no arguments");
     42    NOREF(argv);
     43
    4044    int rc = SUPR3Install();
    4145    if (RT_SUCCESS(rc))
    4246    {
    43         RTPrintf("installed successfully\n");
    44         return 0;
     47        RTMsgInfo("installed successfully");
     48        return RTEXITCODE_SUCCESS;
    4549    }
    46     RTPrintf("installation failed. rc=%Rrc\n", rc);
    47     return 1;
     50    return RTMsgErrorExit(RTEXITCODE_FAILURE, "installation failed. rc=%Rrc", rc);
    4851}
    4952
  • trunk/src/VBox/HostDrivers/Support/testcase/SUPUninstall.cpp

    r38636 r39091  
    55
    66/*
    7  * Copyright (C) 2006-2007 Oracle Corporation
     7 * Copyright (C) 2006-2011 Oracle Corporation
    88 *
    99 * This file is part of VirtualBox Open Source Edition (OSE), as
     
    3333#include <iprt/initterm.h>
    3434#include <iprt/stream.h>
     35#include <iprt/message.h>
    3536
    3637
     
    3839{
    3940    RTR3InitExeNoArguments(0);
     41    if (argc != 1)
     42        return RTMsgErrorExit(RTEXITCODE_SYNTAX, "This utility takes no arguments\n");
     43    NOREF(argv);
     44
    4045    int rc = SUPR3Uninstall();
    4146    if (RT_SUCCESS(rc))
    4247    {
    43         RTPrintf("uninstalled successfully\n");
    44         return 0;
     48        RTMsgInfo("uninstalled successfully");
     49        return RTEXITCODE_SUCCESS;
    4550    }
    46     RTPrintf("uninstallation failed. rc=%Rrc\n", rc);
    47     return 1;
     51    return RTMsgErrorExit(RTEXITCODE_FAILURE, "uninstallation failed. rc=%Rrc", rc);
    4852}
    4953
Note: See TracChangeset for help on using the changeset viewer.

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