VirtualBox

Ignore:
Timestamp:
Jul 24, 2014 2:12:57 PM (11 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
95213
Message:

SUP: Added logging capabilities to the hardened stub.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/HostDrivers/Support/SUPLibInternal.h

    r52160 r52169  
    8989# define supR3HardenedErrorV               supR3HardenedStaticErrorV
    9090# define supR3HardenedError                supR3HardenedStaticError
     91# define supR3HardenedOpenLog              supR3HardenedStaticOpenLog
     92# define supR3HardenedLogV                 supR3HardenedStaticLogV
     93# define supR3HardenedLog                  supR3HardenedStaticLog
    9194# define supR3HardenedVerifyAll            supR3HardenedStaticVerifyAll
    9295# define supR3HardenedVerifyFixedDir       supR3HardenedStaticVerifyFixedDir
     
    131134
    132135/** Debug output macro. */
    133 #ifdef DEBUG_bird
    134 # ifdef IN_SUP_HARDENED_R3
    135 #  define SUP_DPRINTF(a)    suplibHardenedPrintF a
     136#ifdef IN_SUP_HARDENED_R3
     137# if defined(DEBUG_bird) && defined(RT_OS_WINDOWS)
     138#  define SUP_DPRINTF(a)    do { supR3HardenedStaticLog a; suplibHardenedPrintF a; } while (0)
    136139# else
     140#  define SUP_DPRINTF(a)    do { supR3HardenedStaticLog a; } while (0)
     141# endif
     142#else
     143# if defined(DEBUG_bird) && defined(RT_OS_WINDOWS)
    137144#  define SUP_DPRINTF(a)    RTLogPrintf a
     145# else
     146#  define SUP_DPRINTF(a)    do { } while (0)
    138147# endif
    139 #else
    140 # define SUP_DPRINTF(a)     do { } while (0)
    141148#endif
    142149
     
    401408DECLHIDDEN(int)     supR3HardenedError(int rc, bool fFatal, const char *pszFormat, ...);
    402409
     410/**
     411 * Open any startup log file specified in the argument.
     412 */
     413DECLHIDDEN(void)    supR3HardenedOpenLog(int *pcArgs, char **papszArgs);
     414
     415/**
     416 * Write to the startup log file.
     417 */
     418DECLHIDDEN(void)    supR3HardenedLogV(const char *pszFormat, va_list va);
     419
     420/**
     421 * Write to the startup log file.
     422 */
     423DECLHIDDEN(void)    supR3HardenedLog(const char *pszFormat, ...);
     424
     425
    403426DECLHIDDEN(int)     supR3HardenedVerifyAll(bool fFatal, const char *pszProgName);
    404427DECLHIDDEN(int)     supR3HardenedVerifyFixedDir(SUPINSTDIR enmDir, bool fFatal);
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