Changeset 48292 in vbox
- Timestamp:
- Sep 5, 2013 7:27:54 AM (11 years ago)
- Location:
- trunk/src/VBox/GuestHost/OpenGL
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/GuestHost/OpenGL/include/cr_dump.h
r46515 r48292 32 32 RT_C_DECLS_BEGIN 33 33 34 #ifdef RT_OS_WINDOWS 34 35 DECLEXPORT(void) crDmpDumpImgDmlBreak(struct CR_DUMPER * pDumper, CR_BLITTER_IMG *pImg, const char*pszEntryDesc); 35 36 36 37 DECLEXPORT(void) crDmpDumpStrDbgPrint(struct CR_DUMPER * pDumper, const char*pszStr); 38 #endif 37 39 38 40 struct CR_DUMPER; … … 54 56 (_pDumper)->pfnDumpStr((_pDumper), (_pDesc)); \ 55 57 } while (0) 58 59 #ifndef RT_OS_WINDOWS 60 # define vsprintf_s vsnprintf 61 # define sprintf_s snprintf 62 #endif 56 63 57 64 DECLINLINE(void) crDmpStrV(CR_DUMPER *pDumper, const char *pszStr, va_list pArgList) … … 105 112 DECLEXPORT(int) crDmpHtmlInit(struct CR_HTML_DUMPER * pDumper, const char *pszDir, const char *pszFile); 106 113 114 #ifdef RT_OS_WINDOWS 107 115 DECLINLINE(void) crDmpDbgPrintInit(CR_DBGPRINT_DUMPER *pDumper) 108 116 { … … 110 118 pDumper->Base.pfnDumpStr = crDmpDumpStrDbgPrint; 111 119 } 120 #endif 112 121 113 122 typedef struct CR_RECORDER -
trunk/src/VBox/GuestHost/OpenGL/state_tracker/dump.cpp
r46515 r48292 555 555 *pNewLine = '\0'; 556 556 *pcbStr = cbStr - (((uintptr_t)pNewLine) - ((uintptr_t)pszStr)) - 1; 557 Assert((*pcbStr) >= 0);557 Assert((*pcbStr) < UINT32_MAX/2); 558 558 Assert((*pcbStr) < cbStr); 559 559 *ppszStr = pNewLine + 1; … … 1421 1421 } 1422 1422 1423 #ifdef RT_OS_WINDOWS 1423 1424 static void crDmpPrint(const char* szString, ...) 1424 1425 { … … 1454 1455 OutputDebugStringA(pszStr); 1455 1456 } 1457 #endif 1456 1458 1457 1459 static void crDmpHtmlDumpStrExact(struct CR_HTML_DUMPER * pDumper, const char *pszStr)
Note:
See TracChangeset
for help on using the changeset viewer.