Changeset 68995 in vbox for trunk/src/VBox/Runtime
- Timestamp:
- Oct 6, 2017 7:46:09 AM (7 years ago)
- svn:sync-xref-src-repo-rev:
- 118264
- Location:
- trunk/src/VBox/Runtime
- Files:
-
- 1 edited
- 1 copied
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Runtime/Makefile.kmk
r68948 r68995 2198 2198 generic/RTSemEventMultiWait-2-ex-generic.cpp \ 2199 2199 generic/RTSemEventMultiWaitNoResume-2-ex-generic.cpp \ 2200 generic/rtStrFormatKernelAddress-generic.cpp \2201 2200 generic/critsect-generic.cpp \ 2202 2201 generic/errvars-generic.cpp \ … … 2227 2226 generic/RTMpGetCoreCount-generic.cpp \ 2228 2227 generic/mppresent-generic.cpp \ 2228 generic/rtStrFormatKernelAddress-generic.cpp \ 2229 2229 r0drv/linux/alloc-r0drv-linux.c \ 2230 2230 r0drv/linux/assert-r0drv-linux.c \ … … 2357 2357 generic/mppresent-generic-online.cpp \ 2358 2358 generic/RTMpGetCoreCount-generic.cpp \ 2359 generic/rtStrFormatKernelAddress-generic.cpp \ 2359 2360 nt/RTErrConvertFromNtStatus.cpp \ 2360 2361 nt/RTNtPathExpand8dot3Path.cpp \ … … 2413 2414 r0drv/darwin/RTLogWriteDebugger-r0drv-darwin.cpp \ 2414 2415 r0drv/darwin/RTLogWriteStdOut-r0drv-darwin.cpp \ 2416 r0drv/darwin/rtStrFormatKernelAddress-r0drv-darwin.cpp \ 2415 2417 r0drv/darwin/semevent-r0drv-darwin.cpp \ 2416 2418 r0drv/darwin/semeventmulti-r0drv-darwin.cpp \ … … 2521 2523 generic/RTTimerCreate-generic.cpp \ 2522 2524 generic/mppresent-generic.cpp \ 2525 generic/rtStrFormatKernelAddress-generic.cpp \ 2523 2526 r0drv/generic/RTMpIsCpuWorkPending-r0drv-generic.cpp \ 2524 2527 r0drv/generic/mpnotification-r0drv-generic.cpp \ … … 2555 2558 generic/RTTimerCreate-generic.cpp \ 2556 2559 generic/mppresent-generic.cpp \ 2560 generic/rtStrFormatKernelAddress-generic.cpp \ 2557 2561 r0drv/generic/RTMpIsCpuWorkPending-r0drv-generic.cpp \ 2558 2562 r0drv/generic/mpnotification-r0drv-generic.cpp \ … … 2585 2589 generic/RTTimerCreate-generic.cpp \ 2586 2590 generic/mppresent-generic.cpp \ 2591 generic/rtStrFormatKernelAddress-generic.cpp \ 2587 2592 r0drv/memobj-r0drv.cpp \ 2588 2593 r0drv/mpnotification-r0drv.c \ … … 2621 2626 generic/RTTimerCreate-generic.cpp \ 2622 2627 generic/mppresent-generic.cpp \ 2628 generic/rtStrFormatKernelAddress-generic.cpp \ 2623 2629 r0drv/generic/RTMpIsCpuWorkPending-r0drv-generic.cpp \ 2624 2630 r0drv/generic/mpnotification-r0drv-generic.cpp \ -
trunk/src/VBox/Runtime/r0drv/darwin/rtStrFormatKernelAddress-r0drv-darwin.cpp
r68994 r68995 30 30 *********************************************************************************************************************************/ 31 31 #define LOG_GROUP RTLOGGROUP_STRING 32 #include "the- linux-kernel.h"32 #include "the-darwin-kernel.h" 33 33 #include "internal/iprt.h" 34 34 … … 42 42 signed int cchPrecision, unsigned int fFlags) 43 43 { 44 #if !defined(DEBUG) && LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 38) 45 RT_NOREF(cchWidth, cchPrecision); 46 /* use the Linux kernel function which is able to handle "%pK" */ 47 static const char s_szFmt[] = "0x%pK"; 48 const char *pszFmt = s_szFmt; 49 if (!(fFlags & RTSTR_F_SPECIAL)) 50 pszFmt += 2; 51 return scnprintf(pszBuf, cbBuf, pszFmt, uPtr); 52 #else 44 /* 45 * Kernel addresses don't need obfuscation in R0 because the kernel log is only accessible 46 * as root. 47 */ 53 48 Assert(cbBuf >= 64); 54 49 return RTStrFormatNumber(pszBuf, uPtr, 16, cchWidth, cchPrecision, fFlags); 55 #endif56 50 }
Note:
See TracChangeset
for help on using the changeset viewer.