Changeset 91789 in vbox
- Timestamp:
- Oct 17, 2021 6:16:11 PM (3 years ago)
- Location:
- trunk
- Files:
-
- 3 added
- 26 edited
- 2 copied
Legend:
- Unmodified
- Added
- Removed
-
trunk/include/VBox/sup.h
r91785 r91789 2210 2210 2211 2211 /** 2212 * Writes to the debugger and/or kernel log, va_list version. 2213 * 2214 * The length of the formatted message is somewhat limited, so keep things short 2215 * and to the point. 2216 * 2217 * @returns Number of bytes written, mabye. 2218 * @param pszFormat IPRT format string. 2219 * @param va Arguments referenced by the format string. 2220 */ 2221 SUPR0DECL(int) SUPR0PrintfV(const char *pszFormat, va_list va) RT_IPRT_FORMAT_ATTR(1, 0); 2222 2223 /** 2212 2224 * Writes to the debugger and/or kernel log. 2213 2225 * … … 2219 2231 * @param ... Arguments referenced by the format string. 2220 2232 */ 2221 SUPR0DECL(int) SUPR0Printf(const char *pszFormat, ...) RT_IPRT_FORMAT_ATTR(1, 2); 2233 DECLINLINE(int) SUPR0Printf(const char *pszFormat, ...) RT_IPRT_FORMAT_ATTR(1, 2); /* RT_IPRT_FORMAT_ATTR only allowed on proto */ 2234 DECLINLINE(int) SUPR0Printf(const char *pszFormat, ...) 2235 { 2236 va_list va; 2237 va_start(va, pszFormat); 2238 SUPR0PrintfV(pszFormat, va); 2239 va_end(va); 2240 return 0; 2241 } 2222 2242 2223 2243 #ifdef IN_RING0 -
trunk/include/iprt/log.h
r90974 r91789 2124 2124 * @param ... Format arguments. 2125 2125 */ 2126 RTR0DECL(int) RTLogSetR0ThreadNameF(PRTLOGGER pLogger, const char *pszNameFmt, ...) RT_IPRT_FORMAT_ATTR(1, 2); 2126 RTR0DECL(int) RTLogSetR0ThreadNameF(PRTLOGGER pLogger, const char *pszNameFmt, ...) RT_IPRT_FORMAT_ATTR(2, 3); 2127 2128 /** 2129 * Sets the thread name for a thread specific ring-0 logger. 2130 * 2131 * @returns IPRT status code. 2132 * @param pLogger The logger. NULL is not allowed. 2133 * @param pszNameFmt The format string for the thread name. 2134 * @param va Format arguments. 2135 */ 2136 RTR0DECL(int) RTLogSetR0ThreadNameV(PRTLOGGER pLogger, const char *pszNameFmt, va_list va) RT_IPRT_FORMAT_ATTR(2, 0); 2127 2137 2128 2138 /** … … 2353 2363 * @param args Format arguments. 2354 2364 */ 2355 RTDECL(void) RTLogLoggerV(PRTLOGGER pLogger, const char *pszFormat, va_list args) RT_IPRT_FORMAT_ATTR( 3, 0);2365 RTDECL(void) RTLogLoggerV(PRTLOGGER pLogger, const char *pszFormat, va_list args) RT_IPRT_FORMAT_ATTR(2, 0); 2356 2366 2357 2367 /** -
trunk/src/VBox/Additions/common/VBoxGuest/freebsd/Makefile
r90829 r91789 66 66 logrelellipsis.c \ 67 67 logcom.c \ 68 logformat.c 68 logformat.c \ 69 RTLogCreateEx.c 69 70 70 71 .PATH: ${.CURDIR}/common/misc … … 97 98 stringalloc.c \ 98 99 strformat.c \ 100 RTStrFormat.c \ 99 101 strformatnum.c \ 100 102 strformatrt.c \ 101 103 strformattype.c \ 102 104 strprintf.c \ 105 strprintf-ellipsis.c \ 103 106 strprintf2.c \ 107 strprintf2-ellipsis.c \ 104 108 strtonum.c \ 105 109 memchr.c \ -
trunk/src/VBox/Additions/common/VBoxGuest/freebsd/files_vboxguest
r90829 r91789 108 108 ${PATH_ROOT}/src/VBox/Runtime/common/log/logcom.cpp=>common/log/logcom.c \ 109 109 ${PATH_ROOT}/src/VBox/Runtime/common/log/logformat.cpp=>common/log/logformat.c \ 110 ${PATH_ROOT}/src/VBox/Runtime/common/log/RTLogCreateEx.cpp=>common/log/RTLogCreateEx.c \ 110 111 ${PATH_ROOT}/src/VBox/Runtime/common/misc/handletable.cpp=>common/misc/handletable.c \ 111 112 ${PATH_ROOT}/src/VBox/Runtime/common/misc/handletable.h=>common/misc/handletable.h \ … … 133 134 ${PATH_ROOT}/src/VBox/Runtime/common/string/stringalloc.cpp=>common/string/stringalloc.c \ 134 135 ${PATH_ROOT}/src/VBox/Runtime/common/string/strformat.cpp=>common/string/strformat.c \ 136 ${PATH_ROOT}/src/VBox/Runtime/common/string/RTStrFormat.cpp=>common/string/RTStrFormat.c \ 135 137 ${PATH_ROOT}/src/VBox/Runtime/common/string/strformatnum.cpp=>common/string/strformatnum.c \ 136 138 ${PATH_ROOT}/src/VBox/Runtime/common/string/strformatrt.cpp=>common/string/strformatrt.c \ 137 139 ${PATH_ROOT}/src/VBox/Runtime/common/string/strformattype.cpp=>common/string/strformattype.c \ 138 140 ${PATH_ROOT}/src/VBox/Runtime/common/string/strprintf.cpp=>common/string/strprintf.c \ 141 ${PATH_ROOT}/src/VBox/Runtime/common/string/strprintf-ellipsis.cpp=>common/string/strprintf-ellipsis.c \ 139 142 ${PATH_ROOT}/src/VBox/Runtime/common/string/strprintf2.cpp=>common/string/strprintf2.c \ 143 ${PATH_ROOT}/src/VBox/Runtime/common/string/strprintf2-ellipsis.cpp=>common/string/strprintf2-ellipsis.c \ 140 144 ${PATH_ROOT}/src/VBox/Runtime/common/string/strtonum.cpp=>common/string/strtonum.c \ 141 145 ${PATH_ROOT}/src/VBox/Runtime/common/string/memchr.cpp=>common/string/memchr.c \ -
trunk/src/VBox/Additions/common/VBoxGuest/linux/Makefile
r90829 r91789 83 83 common/log/logcom.o \ 84 84 common/log/logformat.o \ 85 common/log/RTLogCreateEx.o \ 85 86 common/misc/RTAssertMsg1Weak.o \ 86 87 common/misc/RTAssertMsg2.o \ … … 104 105 common/string/stringalloc.o \ 105 106 common/string/strformat.o \ 107 common/string/RTStrFormat.o \ 106 108 common/string/strformatnum.o \ 107 109 common/string/strformatrt.o \ 108 110 common/string/strformattype.o \ 109 111 common/string/strprintf.o \ 112 common/string/strprintf-ellipsis.o \ 110 113 common/string/strprintf2.o \ 114 common/string/strprintf2-ellipsis.o \ 111 115 common/string/strtonum.o \ 112 116 common/string/utf-8.o \ -
trunk/src/VBox/Additions/common/VBoxGuest/linux/combined-agnostic.c
r90829 r91789 70 70 #include "common/log/logformat.c" 71 71 #undef LOG_GROUP 72 #include "common/log/RTLogCreateEx.c" 73 #undef LOG_GROUP 72 74 #include "common/misc/RTAssertMsg1Weak.c" 73 75 #undef LOG_GROUP … … 112 114 #include "common/string/strformat.c" 113 115 #undef LOG_GROUP 116 #include "common/string/RTStrFormat.c" 117 #undef LOG_GROUP 114 118 #include "common/string/strformatnum.c" 115 119 #undef LOG_GROUP … … 118 122 #include "common/string/strprintf.c" 119 123 #undef LOG_GROUP 124 #include "common/string/strprintf-ellipsis.c" 125 #undef LOG_GROUP 120 126 #include "common/string/strprintf2.c" 127 #undef LOG_GROUP 128 #include "common/string/strprintf2-ellipsis.c" 121 129 #undef LOG_GROUP 122 130 #include "common/string/strtonum.c" -
trunk/src/VBox/Additions/common/VBoxGuest/linux/files_vboxguest
r90829 r91789 124 124 ${PATH_ROOT}/src/VBox/Runtime/common/log/logformat.cpp=>common/log/logformat.c \ 125 125 ${PATH_ROOT}/src/VBox/Runtime/common/log/logcom.cpp=>common/log/logcom.c \ 126 ${PATH_ROOT}/src/VBox/Runtime/common/log/RTLogCreateEx.cpp=>common/log/RTLogCreateEx.c \ 126 127 ${PATH_ROOT}/src/VBox/Runtime/common/math/gcc/divdi3.c=>common/math/gcc/divdi3.c \ 127 128 ${PATH_ROOT}/src/VBox/Runtime/common/math/gcc/divmoddi4.c=>common/math/gcc/divmoddi4.c \ … … 153 154 ${PATH_ROOT}/src/VBox/Runtime/common/string/stringalloc.cpp=>common/string/stringalloc.c \ 154 155 ${PATH_ROOT}/src/VBox/Runtime/common/string/strformat.cpp=>common/string/strformat.c \ 156 ${PATH_ROOT}/src/VBox/Runtime/common/string/RTStrFormat.cpp=>common/string/RTStrFormat.c \ 155 157 ${PATH_ROOT}/src/VBox/Runtime/common/string/strformatnum.cpp=>common/string/strformatnum.c \ 156 158 ${PATH_ROOT}/src/VBox/Runtime/common/string/strformatrt.cpp=>common/string/strformatrt.c \ 157 159 ${PATH_ROOT}/src/VBox/Runtime/common/string/strformattype.cpp=>common/string/strformattype.c \ 158 160 ${PATH_ROOT}/src/VBox/Runtime/common/string/strprintf.cpp=>common/string/strprintf.c \ 161 ${PATH_ROOT}/src/VBox/Runtime/common/string/strprintf-ellipsis.cpp=>common/string/strprintf-ellipsis.c \ 159 162 ${PATH_ROOT}/src/VBox/Runtime/common/string/strprintf2.cpp=>common/string/strprintf2.c \ 163 ${PATH_ROOT}/src/VBox/Runtime/common/string/strprintf2-ellipsis.cpp=>common/string/strprintf2-ellipsis.c \ 160 164 ${PATH_ROOT}/src/VBox/Runtime/common/string/strtonum.cpp=>common/string/strtonum.c \ 161 165 ${PATH_ROOT}/src/VBox/Runtime/common/string/utf-8.cpp=>common/string/utf-8.c \ -
trunk/src/VBox/HostDrivers/Support/SUPDrv.cpp
r91785 r91789 241 241 { STKOKAY("SUPR0HCPhysToVirt"), (void *)(uintptr_t)SUPR0HCPhysToVirt }, /* only-linux, only-solaris, only-freebsd */ 242 242 #endif 243 { STKBACK("SUPR0Printf "), (void *)(uintptr_t)SUPR0Printf},243 { STKBACK("SUPR0PrintfV"), (void *)(uintptr_t)SUPR0PrintfV }, 244 244 { STKBACK("SUPR0GetSessionGVM"), (void *)(uintptr_t)SUPR0GetSessionGVM }, 245 245 { STKBACK("SUPR0GetSessionVM"), (void *)(uintptr_t)SUPR0GetSessionVM }, … … 298 298 { STKBACK("RTLogBulkUpdate"), (void *)(uintptr_t)RTLogBulkUpdate}, 299 299 { STKBACK("RTLogCheckGroupFlags"), (void *)(uintptr_t)RTLogCheckGroupFlags }, 300 { STKBACK("RTLogCreateEx "), (void *)(uintptr_t)RTLogCreateEx},300 { STKBACK("RTLogCreateExV"), (void *)(uintptr_t)RTLogCreateExV }, 301 301 { STKBACK("RTLogDestroy"), (void *)(uintptr_t)RTLogDestroy }, 302 302 { STKBACK("RTLogDefaultInstance"), (void *)(uintptr_t)RTLogDefaultInstance }, … … 314 314 { STKBACK("RTLogSetFlushCallback"), (void *)(uintptr_t)RTLogSetFlushCallback }, 315 315 { STKBACK("RTLogSetR0ProgramStart"), (void *)(uintptr_t)RTLogSetR0ProgramStart }, 316 { STKBACK("RTLogSetR0ThreadName F"), (void *)(uintptr_t)RTLogSetR0ThreadNameF},316 { STKBACK("RTLogSetR0ThreadNameV"), (void *)(uintptr_t)RTLogSetR0ThreadNameV }, 317 317 { STKBACK("RTMemAllocExTag"), (void *)(uintptr_t)RTMemAllocExTag }, 318 318 { STKBACK("RTMemAllocTag"), (void *)(uintptr_t)RTMemAllocTag }, … … 345 345 { STKBACK("RTMpOnSpecific"), (void *)(uintptr_t)RTMpOnSpecific }, 346 346 { STKBACK("RTMpPokeCpu"), (void *)(uintptr_t)RTMpPokeCpu }, 347 { STK BACK("RTNetIPv4AddDataChecksum"), (void *)(uintptr_t)RTNetIPv4AddDataChecksum },348 { STK BACK("RTNetIPv4AddTCPChecksum"), (void *)(uintptr_t)RTNetIPv4AddTCPChecksum },349 { STK BACK("RTNetIPv4AddUDPChecksum"), (void *)(uintptr_t)RTNetIPv4AddUDPChecksum },350 { STK BACK("RTNetIPv4FinalizeChecksum"), (void *)(uintptr_t)RTNetIPv4FinalizeChecksum },347 { STKOKAY("RTNetIPv4AddDataChecksum"), (void *)(uintptr_t)RTNetIPv4AddDataChecksum }, 348 { STKOKAY("RTNetIPv4AddTCPChecksum"), (void *)(uintptr_t)RTNetIPv4AddTCPChecksum }, 349 { STKOKAY("RTNetIPv4AddUDPChecksum"), (void *)(uintptr_t)RTNetIPv4AddUDPChecksum }, 350 { STKOKAY("RTNetIPv4FinalizeChecksum"), (void *)(uintptr_t)RTNetIPv4FinalizeChecksum }, 351 351 { STKOKAY("RTNetIPv4HdrChecksum"), (void *)(uintptr_t)RTNetIPv4HdrChecksum }, 352 352 { STKOKAY("RTNetIPv4IsDHCPValid"), (void *)(uintptr_t)RTNetIPv4IsDHCPValid }, … … 444 444 { STKOKAY("RTStrCopy"), (void *)(uintptr_t)RTStrCopy }, 445 445 { STKBACK("RTStrDupTag"), (void *)(uintptr_t)RTStrDupTag }, 446 { STKBACK("RTStrFormat"), (void *)(uintptr_t)RTStrFormat },447 446 { STKBACK("RTStrFormatNumber"), (void *)(uintptr_t)RTStrFormatNumber }, 448 447 { STKBACK("RTStrFormatTypeDeregister"), (void *)(uintptr_t)RTStrFormatTypeDeregister }, … … 452 451 { STKBACK("RTStrFree"), (void *)(uintptr_t)RTStrFree }, 453 452 { STKOKAY("RTStrNCmp"), (void *)(uintptr_t)RTStrNCmp }, 454 { STKBACK("RTStrPrintf"), (void *)(uintptr_t)RTStrPrintf },455 { STKBACK("RTStrPrintfEx"), (void *)(uintptr_t)RTStrPrintfEx },456 453 { STKBACK("RTStrPrintfExV"), (void *)(uintptr_t)RTStrPrintfExV }, 457 454 { STKBACK("RTStrPrintfV"), (void *)(uintptr_t)RTStrPrintfV }, 455 { STKBACK("RTStrPrintf2ExV"), (void *)(uintptr_t)RTStrPrintf2ExV }, 456 { STKBACK("RTStrPrintf2V"), (void *)(uintptr_t)RTStrPrintf2V }, 458 457 { STKBACK("RTThreadCreate"), (void *)(uintptr_t)RTThreadCreate }, 459 458 { STKBACK("RTThreadCtxHookIsEnabled"), (void *)(uintptr_t)RTThreadCtxHookIsEnabled }, -
trunk/src/VBox/HostDrivers/Support/darwin/SUPDrv-darwin.cpp
r90780 r91789 2023 2023 2024 2024 2025 RTDECL(int) SUPR0Printf (const char *pszFormat, ...)2025 RTDECL(int) SUPR0PrintfV(const char *pszFormat, va_list va) 2026 2026 { 2027 2027 IPRT_DARWIN_SAVE_EFL_AC(); 2028 va_list va; 2029 char szMsg[512]; 2030 2031 va_start(va, pszFormat); 2028 2029 char szMsg[512]; 2032 2030 RTStrPrintfV(szMsg, sizeof(szMsg) - 1, pszFormat, va); 2033 va_end(va);2034 2031 szMsg[sizeof(szMsg) - 1] = '\0'; 2035 2032 -
trunk/src/VBox/HostDrivers/Support/freebsd/Makefile
r90829 r91789 69 69 logrelellipsis.c \ 70 70 logcom.c \ 71 logformat.c 71 logformat.c \ 72 RTLogCreateEx.c 72 73 73 74 .PATH: ${.CURDIR}/common/misc … … 97 98 RTStrEnd.c \ 98 99 strformat.c \ 100 RTStrFormat.c \ 99 101 strformatnum.c \ 100 102 strformatrt.c \ 101 103 strformattype.c \ 102 104 strprintf.c \ 105 strprintf-ellipsis.c \ 103 106 strprintf2.c \ 107 strprintf2-ellipsis.c \ 104 108 strtonum.c \ 105 109 memchr.c \ -
trunk/src/VBox/HostDrivers/Support/freebsd/SUPDrv-freebsd.c
r91785 r91789 650 650 651 651 652 SUPR0DECL(int) SUPR0Printf(const char *pszFormat, ...) 653 { 654 va_list va; 652 SUPR0DECL(int) SUPR0PrintfV(const char *pszFormat, va_list va) 653 { 655 654 char szMsg[256]; 656 int cch; 657 658 va_start(va, pszFormat); 659 cch = RTStrPrintfV(szMsg, sizeof(szMsg), pszFormat, va); 660 va_end(va); 655 RTStrPrintfV(szMsg, sizeof(szMsg), pszFormat, va); 656 szMsg[sizeof(szMsg) - 1] = '\0'; 661 657 662 658 printf("%s", szMsg); 663 664 return cch; 659 return 0; 665 660 } 666 661 -
trunk/src/VBox/HostDrivers/Support/freebsd/files_vboxdrv
r90829 r91789 109 109 ${PATH_ROOT}/src/VBox/Runtime/common/log/logcom.cpp=>common/log/logcom.c \ 110 110 ${PATH_ROOT}/src/VBox/Runtime/common/log/logformat.cpp=>common/log/logformat.c \ 111 ${PATH_ROOT}/src/VBox/Runtime/common/log/RTLogCreateEx.cpp=>common/log/RTLogCreateEx.c \ 111 112 ${PATH_ROOT}/src/VBox/Runtime/common/misc/RTAssertMsg1Weak.cpp=>common/misc/RTAssertMsg1Weak.c \ 112 113 ${PATH_ROOT}/src/VBox/Runtime/common/misc/RTAssertMsg2.cpp=>common/misc/RTAssertMsg2.c \ … … 131 132 ${PATH_ROOT}/src/VBox/Runtime/common/string/RTStrNLen.cpp=>common/string/RTStrNLen.c \ 132 133 ${PATH_ROOT}/src/VBox/Runtime/common/string/strformat.cpp=>common/string/strformat.c \ 134 ${PATH_ROOT}/src/VBox/Runtime/common/string/RTStrFormat.cpp=>common/string/RTStrFormat.c \ 133 135 ${PATH_ROOT}/src/VBox/Runtime/common/string/strformatnum.cpp=>common/string/strformatnum.c \ 134 136 ${PATH_ROOT}/src/VBox/Runtime/common/string/strformatrt.cpp=>common/string/strformatrt.c \ 135 137 ${PATH_ROOT}/src/VBox/Runtime/common/string/strformattype.cpp=>common/string/strformattype.c \ 136 138 ${PATH_ROOT}/src/VBox/Runtime/common/string/strprintf.cpp=>common/string/strprintf.c \ 139 ${PATH_ROOT}/src/VBox/Runtime/common/string/strprintf-ellipsis.cpp=>common/string/strprintf-ellipsis.c \ 137 140 ${PATH_ROOT}/src/VBox/Runtime/common/string/strprintf2.cpp=>common/string/strprintf2.c \ 141 ${PATH_ROOT}/src/VBox/Runtime/common/string/strprintf2-ellipsis.cpp=>common/string/strprintf2-ellipsis.c \ 138 142 ${PATH_ROOT}/src/VBox/Runtime/common/string/strtonum.cpp=>common/string/strtonum.c \ 139 143 ${PATH_ROOT}/src/VBox/Runtime/common/string/memchr.cpp=>common/string/memchr.c \ -
trunk/src/VBox/HostDrivers/Support/linux/Makefile
r90829 r91789 85 85 common/log/logcom.o \ 86 86 common/log/logformat.o \ 87 common/log/RTLogCreateEx.o \ 87 88 common/misc/RTAssertMsg1Weak.o \ 88 89 common/misc/RTAssertMsg2.o \ … … 105 106 common/string/stringalloc.o \ 106 107 common/string/strformat.o \ 108 common/string/RTStrFormat.o \ 107 109 common/string/strformatnum.o \ 108 110 common/string/strformattype.o \ 109 111 common/string/strprintf.o \ 112 common/string/strprintf-ellipsis.o \ 110 113 common/string/strprintf2.o \ 114 common/string/strprintf2-ellipsis.o \ 111 115 common/string/strtonum.o \ 112 116 common/table/avlpv.o \ -
trunk/src/VBox/HostDrivers/Support/linux/SUPDrv-linux.c
r91552 r91789 1694 1694 1695 1695 1696 RTDECL(int) SUPR0Printf(const char *pszFormat, ...) 1697 { 1698 va_list va; 1696 RTDECL(int) SUPR0PrintfV(const char *pszFormat, va_list va) 1697 { 1699 1698 char szMsg[512]; 1700 1699 IPRT_LINUX_SAVE_EFL_AC(); 1701 1700 1702 va_start(va, pszFormat);1703 1701 RTStrPrintfV(szMsg, sizeof(szMsg) - 1, pszFormat, va); 1704 va_end(va);1705 1702 szMsg[sizeof(szMsg) - 1] = '\0'; 1706 1703 -
trunk/src/VBox/HostDrivers/Support/linux/combined-agnostic1.c
r85523 r91789 64 64 #include "common/log/logformat.c" 65 65 #undef LOG_GROUP 66 #include "common/log/RTLogCreateEx.c" 67 #undef LOG_GROUP 66 68 #include "common/misc/RTAssertMsg1Weak.c" 67 69 #undef LOG_GROUP -
trunk/src/VBox/HostDrivers/Support/linux/combined-agnostic2.c
r90829 r91789 48 48 #include "common/string/strformat.c" 49 49 #undef LOG_GROUP 50 #include "common/string/RTStrFormat.c" 51 #undef LOG_GROUP 50 52 #include "common/string/strformatnum.c" 51 53 #undef LOG_GROUP … … 54 56 #include "common/string/strprintf.c" 55 57 #undef LOG_GROUP 58 #include "common/string/strprintf-ellipsis.c" 59 #undef LOG_GROUP 56 60 #include "common/string/strprintf2.c" 61 #undef LOG_GROUP 62 #include "common/string/strprintf2-ellipsis.c" 57 63 #undef LOG_GROUP 58 64 #include "common/string/strtonum.c" -
trunk/src/VBox/HostDrivers/Support/linux/files_vboxdrv
r90829 r91789 114 114 ${PATH_ROOT}/src/VBox/Runtime/common/log/logcom.cpp=>common/log/logcom.c \ 115 115 ${PATH_ROOT}/src/VBox/Runtime/common/log/logformat.cpp=>common/log/logformat.c \ 116 ${PATH_ROOT}/src/VBox/Runtime/common/log/RTLogCreateEx.cpp=>common/log/RTLogCreateEx.c \ 116 117 ${PATH_ROOT}/src/VBox/Runtime/common/math/gcc/divdi3.c=>math/gcc/divdi3.c \ 117 118 ${PATH_ROOT}/src/VBox/Runtime/common/math/gcc/divmoddi4.c=>math/gcc/divmoddi4.c \ … … 143 144 ${PATH_ROOT}/src/VBox/Runtime/common/string/stringalloc.cpp=>common/string/stringalloc.c \ 144 145 ${PATH_ROOT}/src/VBox/Runtime/common/string/strformat.cpp=>common/string/strformat.c \ 146 ${PATH_ROOT}/src/VBox/Runtime/common/string/RTStrFormat.cpp=>common/string/RTStrFormat.c \ 145 147 ${PATH_ROOT}/src/VBox/Runtime/common/string/strformatnum.cpp=>common/string/strformatnum.c \ 146 148 ${PATH_ROOT}/src/VBox/Runtime/common/string/strformatrt.cpp=>common/string/strformatrt.c \ 147 149 ${PATH_ROOT}/src/VBox/Runtime/common/string/strformattype.cpp=>common/string/strformattype.c \ 148 150 ${PATH_ROOT}/src/VBox/Runtime/common/string/strprintf.cpp=>common/string/strprintf.c \ 151 ${PATH_ROOT}/src/VBox/Runtime/common/string/strprintf-ellipsis.cpp=>common/string/strprintf-ellipsis.c \ 149 152 ${PATH_ROOT}/src/VBox/Runtime/common/string/strprintf2.cpp=>common/string/strprintf2.c \ 153 ${PATH_ROOT}/src/VBox/Runtime/common/string/strprintf2-ellipsis.cpp=>common/string/strprintf2-ellipsis.c \ 150 154 ${PATH_ROOT}/src/VBox/Runtime/common/string/strtonum.cpp=>common/string/strtonum.c \ 151 155 ${PATH_ROOT}/src/VBox/Runtime/common/table/avlpv.cpp=>common/table/avlpv.c \ -
trunk/src/VBox/HostDrivers/Support/os2/SUPDrv-os2.cpp
r87700 r91789 536 536 537 537 538 SUPR0DECL(int) SUPR0Printf(const char *pszFormat, ...) 539 { 540 va_list va; 541 538 SUPR0DECL(int) SUPR0PrintfV(const char *pszFormat, va_list va) 539 { 542 540 #if 0 //def DEBUG_bird 543 va_start(va, pszFormat); 544 RTLogComPrintfV(pszFormat, va); 545 va_end(va); 541 va_list va2; 542 va_copy(va2, va); 543 RTLogComPrintfV(pszFormat, va2); 544 va_end(va2); 546 545 #endif 547 546 548 va_start(va, pszFormat); 549 int cch = RTLogFormatV(VBoxDrvLogOutput, NULL, pszFormat, va); 550 va_end(va); 551 552 return cch; 547 RTLogFormatV(VBoxDrvLogOutput, NULL, pszFormat, va); 548 return 0; 553 549 } 554 550 -
trunk/src/VBox/HostDrivers/Support/solaris/SUPDrv-solaris.c
r90780 r91789 1303 1303 1304 1304 1305 RTDECL(int) SUPR0Printf(const char *pszFormat, ...) 1306 { 1307 va_list args; 1308 char szMsg[512]; 1309 1305 RTDECL(int) SUPR0PrintfV(const char *pszFormat, va_list va) 1306 { 1310 1307 /* cmn_err() acquires adaptive mutexes. Not preemption safe, see @bugref{6657}. */ 1311 if (!RTThreadPreemptIsEnabled(NIL_RTTHREAD)) 1312 return 0; 1313 1314 va_start(args, pszFormat); 1315 RTStrPrintfV(szMsg, sizeof(szMsg) - 1, pszFormat, args); 1316 va_end(args); 1317 1318 szMsg[sizeof(szMsg) - 1] = '\0'; 1319 cmn_err(CE_CONT, "%s", szMsg); 1308 if (RTThreadPreemptIsEnabled(NIL_RTTHREAD)) 1309 { 1310 char szMsg[512]; 1311 RTStrPrintfV(szMsg, sizeof(szMsg) - 1, pszFormat, va); 1312 szMsg[sizeof(szMsg) - 1] = '\0'; 1313 1314 cmn_err(CE_CONT, "%s", szMsg); 1315 } 1320 1316 return 0; 1321 1317 } -
trunk/src/VBox/HostDrivers/Support/win/SUPDrv-win.cpp
r91559 r91789 2952 2952 2953 2953 2954 SUPR0DECL(int) SUPR0Printf(const char *pszFormat, ...) 2955 { 2956 va_list va; 2957 char szMsg[384]; 2958 2959 va_start(va, pszFormat); 2954 SUPR0DECL(int) SUPR0PrintfV(const char *pszFormat, va_list va) 2955 { 2956 char szMsg[384]; 2960 2957 size_t cch = RTStrPrintfV(szMsg, sizeof(szMsg) - 1, pszFormat, va); 2961 2958 szMsg[sizeof(szMsg) - 1] = '\0'; 2962 va_end(va);2963 2959 2964 2960 RTLogWriteDebugger(szMsg, cch); -
trunk/src/VBox/Runtime/Makefile.kmk
r91559 r91789 501 501 common/log/tracelogreader.cpp \ 502 502 common/log/tracelogwriter.cpp \ 503 common/log/RTLogCreateEx.cpp \ 503 504 common/math/bignum.cpp \ 504 505 common/misc/RTAssertMsg1Weak.cpp \ … … 626 627 common/string/straprintf.cpp \ 627 628 common/string/strformat.cpp \ 629 common/string/RTStrFormat.cpp \ 628 630 common/string/strformatnum.cpp \ 629 631 common/string/strformatrt.cpp \ … … 632 634 common/string/stringalloc.cpp \ 633 635 common/string/strprintf.cpp \ 636 common/string/strprintf-ellipsis.cpp \ 634 637 common/string/strprintf2.cpp \ 638 common/string/strprintf2-ellipsis.cpp \ 635 639 common/string/strcache.cpp \ 636 640 common/string/strspace.cpp \ … … 1816 1820 common/log/logrel.cpp \ 1817 1821 common/log/logrelellipsis.cpp \ 1822 common/log/RTLogCreateEx.cpp \ 1818 1823 common/math/bignum.cpp \ 1819 1824 common/misc/assert.cpp \ … … 1898 1903 common/string/strcache.cpp \ 1899 1904 common/string/strformat.cpp \ 1905 common/string/RTStrFormat.cpp \ 1900 1906 common/string/strformatnum.cpp \ 1901 1907 common/string/strformatrt.cpp \ … … 1904 1910 common/string/stringalloc.cpp \ 1905 1911 common/string/strprintf.cpp \ 1912 common/string/strprintf-ellipsis.cpp \ 1906 1913 common/string/strprintf2.cpp \ 1914 common/string/strprintf2-ellipsis.cpp \ 1907 1915 common/string/strspace.cpp \ 1908 1916 common/string/strstrip.cpp \ … … 2664 2672 common/string/straprintf.cpp \ 2665 2673 common/string/strformat.cpp \ 2674 common/string/RTStrFormat.cpp \ 2666 2675 common/string/strformatnum.cpp \ 2667 2676 common/string/strformatrt.cpp \ 2668 2677 common/string/strformattype.cpp \ 2669 2678 common/string/strprintf.cpp \ 2679 common/string/strprintf-ellipsis.cpp \ 2670 2680 common/string/strprintf2.cpp \ 2681 common/string/strprintf2-ellipsis.cpp \ 2671 2682 common/string/stringalloc.cpp \ 2672 2683 common/string/strtonum.cpp \ … … 2741 2752 common/log/tracebuf.cpp \ 2742 2753 common/log/tracedefault.cpp \ 2754 common/log/RTLogCreateEx.cpp \ 2755 common/log/RTLogSetR0ThreadNameF.cpp \ 2743 2756 common/misc/RTAssertMsg1Weak.cpp \ 2744 2757 common/misc/RTAssertMsg2.cpp \ … … 2754 2767 common/misc/term.cpp \ 2755 2768 common/path/RTPathFilename.cpp \ 2769 common/string/strprintf-ellipsis.cpp \ 2770 common/string/strprintf2-ellipsis.cpp \ 2756 2771 common/string/strhash1.cpp \ 2757 2772 common/string/strncmp.cpp \ … … 2927 2942 common/log/tracebuf.cpp \ 2928 2943 common/log/tracedefault.cpp \ 2944 common/log/RTLogCreateEx.cpp \ 2929 2945 common/misc/RTAssertMsg1Weak.cpp \ 2930 2946 common/misc/RTAssertMsg2.cpp \ … … 2980 2996 common/string/straprintf.cpp \ 2981 2997 common/string/strformat.cpp \ 2998 common/string/RTStrFormat.cpp \ 2982 2999 common/string/strformatnum.cpp \ 2983 3000 common/string/strformatrt.cpp \ … … 2985 3002 common/string/strhash1.cpp \ 2986 3003 common/string/strprintf.cpp \ 3004 common/string/strprintf-ellipsis.cpp \ 2987 3005 common/string/strprintf2.cpp \ 3006 common/string/strprintf2-ellipsis.cpp \ 2988 3007 common/string/strtonum.cpp \ 2989 3008 common/string/stringalloc.cpp \ … … 3664 3683 common/log/tracebuf.cpp \ 3665 3684 common/log/tracedefault.cpp \ 3685 common/log/RTLogCreateEx.cpp \ 3666 3686 common/misc/RTAssertMsg1Weak.cpp \ 3667 3687 common/misc/RTAssertMsg2.cpp \ … … 3677 3697 common/path/RTPathFilename.cpp \ 3678 3698 common/string/strformat.cpp \ 3699 common/string/RTStrFormat.cpp \ 3679 3700 common/string/strformatnum.cpp \ 3680 3701 common/string/strformatrt.cpp \ … … 3683 3704 common/string/strpbrk.cpp \ 3684 3705 common/string/strprintf.cpp \ 3706 common/string/strprintf-ellipsis.cpp \ 3685 3707 common/string/strprintf2.cpp \ 3708 common/string/strprintf2-ellipsis.cpp \ 3686 3709 common/string/RTStrCmp.cpp \ 3687 3710 common/string/RTStrCopy.cpp \ -
trunk/src/VBox/Runtime/common/log/log.cpp
r90974 r91789 1355 1355 1356 1356 1357 RTDECL(int) RTLogCreateEx(PRTLOGGER *ppLogger, const char *pszEnvVarBase, uint64_t fFlags, const char *pszGroupSettings,1358 unsigned cGroups, const char * const *papszGroups, uint32_t cMaxEntriesPerGroup,1359 uint32_t cBufDescs, PRTLOGBUFFERDESC paBufDescs, uint32_t fDestFlags,1360 PFNRTLOGPHASE pfnPhase, uint32_t cHistory, uint64_t cbHistoryFileMax, uint32_t cSecsHistoryTimeSlot,1361 PRTERRINFO pErrInfo, const char *pszFilenameFmt, ...)1362 {1363 va_list va;1364 int rc;1365 1366 va_start(va, pszFilenameFmt);1367 rc = RTLogCreateExV(ppLogger, pszEnvVarBase, fFlags, pszGroupSettings, cGroups, papszGroups, cMaxEntriesPerGroup,1368 cBufDescs, paBufDescs, fDestFlags,1369 pfnPhase, cHistory, cbHistoryFileMax, cSecsHistoryTimeSlot,1370 pErrInfo, pszFilenameFmt, va);1371 va_end(va);1372 return rc;1373 }1374 RT_EXPORT_SYMBOL(RTLogCreateEx);1375 1376 1377 1357 /** 1378 1358 * Destroys a logger instance. … … 2056 2036 #ifdef IN_RING0 2057 2037 2058 RTR0DECL(int) RTLogSetR0ThreadName F(PRTLOGGER pLogger, const char *pszNameFmt, ...)2038 RTR0DECL(int) RTLogSetR0ThreadNameV(PRTLOGGER pLogger, const char *pszNameFmt, va_list va) 2059 2039 { 2060 2040 PRTLOGGERINTERNAL pLoggerInt = (PRTLOGGERINTERNAL)pLogger; … … 2062 2042 if (pLoggerInt) 2063 2043 { 2064 va_list va;2065 va_start(va, pszNameFmt);2066 2067 2044 rc = rtlogLock(pLoggerInt); 2068 2045 if (RT_SUCCESS(rc)) … … 2072 2049 rc = cch > 0 ? VINF_SUCCESS : VERR_BUFFER_OVERFLOW; 2073 2050 } 2074 2075 va_end(va);2076 2051 } 2077 2052 else … … 2079 2054 return rc; 2080 2055 } 2081 RT_EXPORT_SYMBOL(RTLogSetR0ThreadName F);2056 RT_EXPORT_SYMBOL(RTLogSetR0ThreadNameV); 2082 2057 2083 2058 -
trunk/src/VBox/Runtime/common/string/strformat.cpp
r90821 r91789 833 833 RT_EXPORT_SYMBOL(RTStrFormatV); 834 834 835 836 /**837 * Partial implementation of a printf like formatter.838 * It doesn't do everything correct, and there is no floating point support.839 * However, it supports custom formats by the means of a format callback.840 *841 * @returns number of bytes formatted.842 * @param pfnOutput Output worker.843 * Called in two ways. Normally with a string an it's length.844 * For termination, it's called with NULL for string, 0 for length.845 * @param pvArgOutput Argument to the output worker.846 * @param pfnFormat Custom format worker.847 * @param pvArgFormat Argument to the format worker.848 * @param pszFormat Format string.849 * @param ... Argument list.850 */851 RTDECL(size_t) RTStrFormat(PFNRTSTROUTPUT pfnOutput, void *pvArgOutput, PFNSTRFORMAT pfnFormat, void *pvArgFormat, const char *pszFormat, ...)852 {853 size_t cch;854 va_list args;855 va_start(args, pszFormat);856 cch = RTStrFormatV(pfnOutput, pvArgOutput, pfnFormat, pvArgFormat, pszFormat, args);857 va_end(args);858 return cch;859 }860 RT_EXPORT_SYMBOL(RTStrFormat);861 -
trunk/src/VBox/Runtime/common/string/strprintf-ellipsis.cpp
r91787 r91789 1 1 /* $Id$ */ 2 2 /** @file 3 * IPRT - String Formatters .3 * IPRT - String Formatters, Ellipsis Functions. 4 4 */ 5 5 … … 32 32 #include "internal/iprt.h" 33 33 34 #include <iprt/assert.h>35 36 37 /*********************************************************************************************************************************38 * Structures and Typedefs *39 *********************************************************************************************************************************/40 /** strbufoutput() argument structure. */41 typedef struct STRBUFARG42 {43 /** Pointer to current buffer position. */44 char *psz;45 /** Number of bytes left in the buffer - not including the trailing zero. */46 size_t cch;47 } STRBUFARG;48 /** Pointer to a strbufoutput() argument structure. */49 typedef STRBUFARG *PSTRBUFARG;50 51 52 /*********************************************************************************************************************************53 * Internal Functions *54 *********************************************************************************************************************************/55 static DECLCALLBACK(size_t) strbufoutput(void *pvArg, const char *pachChars, size_t cbChars);56 57 58 /**59 * Output callback.60 *61 * @returns number of bytes written.62 * @param pvArg Pointer to a STRBUFARG structure.63 * @param pachChars Pointer to an array of utf-8 characters.64 * @param cbChars Number of bytes in the character array pointed to by pachChars.65 */66 static DECLCALLBACK(size_t) strbufoutput(void *pvArg, const char *pachChars, size_t cbChars)67 {68 PSTRBUFARG pArg = (PSTRBUFARG)pvArg;69 char *pszCur = pArg->psz; /* We actually have to spell this out for VS2010, or it will load for each case. */70 71 cbChars = RT_MIN(pArg->cch, cbChars);72 if (cbChars)73 {74 pArg->cch -= cbChars;75 76 /* Note! For VS2010/64 we need at least 7 case statements before it generates a jump table. */77 switch (cbChars)78 {79 default:80 memcpy(pszCur, pachChars, cbChars);81 break;82 case 8: pszCur[7] = pachChars[7]; RT_FALL_THRU();83 case 7: pszCur[6] = pachChars[6]; RT_FALL_THRU();84 case 6: pszCur[5] = pachChars[5]; RT_FALL_THRU();85 case 5: pszCur[4] = pachChars[4]; RT_FALL_THRU();86 case 4: pszCur[3] = pachChars[3]; RT_FALL_THRU();87 case 3: pszCur[2] = pachChars[2]; RT_FALL_THRU();88 case 2: pszCur[1] = pachChars[1]; RT_FALL_THRU();89 case 1: pszCur[0] = pachChars[0]; RT_FALL_THRU();90 case 0:91 break;92 }93 pArg->psz = pszCur += cbChars;94 }95 *pszCur = '\0';96 97 return cbChars;98 }99 100 101 RTDECL(size_t) RTStrPrintfV(char *pszBuffer, size_t cchBuffer, const char *pszFormat, va_list args)102 {103 STRBUFARG Arg;104 AssertMsgReturn(cchBuffer, ("Excellent idea! Format a string with no space for the output!\n"), 0);105 Arg.psz = pszBuffer;106 Arg.cch = cchBuffer - 1;107 return RTStrFormatV(strbufoutput, &Arg, NULL, NULL, pszFormat, args);108 }109 RT_EXPORT_SYMBOL(RTStrPrintfV);110 111 34 112 35 RTDECL(size_t) RTStrPrintf(char *pszBuffer, size_t cchBuffer, const char *pszFormat, ...) … … 122 45 123 46 124 RTDECL(size_t) RTStrPrintfExV(PFNSTRFORMAT pfnFormat, void *pvArg, char *pszBuffer, size_t cchBuffer, const char *pszFormat, va_list args)125 {126 STRBUFARG Arg;127 AssertMsgReturn(cchBuffer, ("Excellent idea! Format a string with no space for the output!\n"), 0);128 Arg.psz = pszBuffer;129 Arg.cch = cchBuffer - 1;130 return RTStrFormatV(strbufoutput, &Arg, pfnFormat, pvArg, pszFormat, args);131 }132 RT_EXPORT_SYMBOL(RTStrPrintfExV);133 134 135 136 47 RTDECL(size_t) RTStrPrintfEx(PFNSTRFORMAT pfnFormat, void *pvArg, char *pszBuffer, size_t cchBuffer, const char *pszFormat, ...) 137 48 { -
trunk/src/VBox/Runtime/common/string/strprintf.cpp
r91787 r91789 110 110 111 111 112 RTDECL(size_t) RTStrPrintf(char *pszBuffer, size_t cchBuffer, const char *pszFormat, ...)113 {114 size_t cbRet;115 va_list va;116 va_start(va, pszFormat);117 cbRet = RTStrPrintfV(pszBuffer, cchBuffer, pszFormat, va);118 va_end(va);119 return cbRet;120 }121 RT_EXPORT_SYMBOL(RTStrPrintf);122 123 124 112 RTDECL(size_t) RTStrPrintfExV(PFNSTRFORMAT pfnFormat, void *pvArg, char *pszBuffer, size_t cchBuffer, const char *pszFormat, va_list args) 125 113 { … … 132 120 RT_EXPORT_SYMBOL(RTStrPrintfExV); 133 121 134 135 136 RTDECL(size_t) RTStrPrintfEx(PFNSTRFORMAT pfnFormat, void *pvArg, char *pszBuffer, size_t cchBuffer, const char *pszFormat, ...)137 {138 va_list args;139 size_t cbRet;140 va_start(args, pszFormat);141 cbRet = RTStrPrintfExV(pfnFormat, pvArg, pszBuffer, cchBuffer, pszFormat, args);142 va_end(args);143 return cbRet;144 }145 RT_EXPORT_SYMBOL(RTStrPrintfEx);146 -
trunk/src/VBox/Runtime/common/string/strprintf2-ellipsis.cpp
r91788 r91789 1 1 /* $Id$ */ 2 2 /** @file 3 * IPRT - String Formatters, alternative .3 * IPRT - String Formatters, alternative, ellipsis. 4 4 */ 5 5 … … 32 32 #include "internal/iprt.h" 33 33 34 #include <iprt/assert.h>35 36 37 /*********************************************************************************************************************************38 * Structures and Typedefs *39 *********************************************************************************************************************************/40 /** rtStrPrintf2Output() argument structure. */41 typedef struct STRPRINTF2OUTPUTARGS42 {43 /** Pointer to current buffer position. */44 char *pszCur;45 /** Number of bytes left in the buffer (including the trailing zero). */46 size_t cbLeft;47 /** Set if we overflowed. */48 bool fOverflowed;49 } STRPRINTF2OUTPUTARGS;50 /** Pointer to a rtStrPrintf2Output() argument structure. */51 typedef STRPRINTF2OUTPUTARGS *PSTRPRINTF2OUTPUTARGS;52 53 54 /**55 * Output callback.56 *57 * @returns cbChars58 *59 * @param pvArg Pointer to a STRBUFARG structure.60 * @param pachChars Pointer to an array of utf-8 characters.61 * @param cbChars Number of bytes in the character array pointed to by pachChars.62 */63 static DECLCALLBACK(size_t) rtStrPrintf2Output(void *pvArg, const char *pachChars, size_t cbChars)64 {65 PSTRPRINTF2OUTPUTARGS pArgs = (PSTRPRINTF2OUTPUTARGS)pvArg;66 char *pszCur = pArgs->pszCur; /* We actually have to spell this out for VS2010, or it will load it for each case. */67 68 if (cbChars < pArgs->cbLeft)69 {70 pArgs->cbLeft -= cbChars;71 72 /* Note! For VS2010/64 we need at least 7 case statements before it generates a jump table. */73 switch (cbChars)74 {75 default:76 memcpy(pszCur, pachChars, cbChars);77 break;78 case 8: pszCur[7] = pachChars[7]; RT_FALL_THRU();79 case 7: pszCur[6] = pachChars[6]; RT_FALL_THRU();80 case 6: pszCur[5] = pachChars[5]; RT_FALL_THRU();81 case 5: pszCur[4] = pachChars[4]; RT_FALL_THRU();82 case 4: pszCur[3] = pachChars[3]; RT_FALL_THRU();83 case 3: pszCur[2] = pachChars[2]; RT_FALL_THRU();84 case 2: pszCur[1] = pachChars[1]; RT_FALL_THRU();85 case 1: pszCur[0] = pachChars[0]; RT_FALL_THRU();86 case 0:87 break;88 }89 pArgs->pszCur = pszCur += cbChars;90 *pszCur = '\0';91 }92 else93 {94 size_t cbLeft = pArgs->cbLeft;95 if (cbLeft-- > 1)96 {97 memcpy(pszCur, pachChars, cbLeft);98 pArgs->pszCur = pszCur += cbLeft;99 *pszCur = '\0';100 pArgs->cbLeft = 1;101 }102 pArgs->fOverflowed = true;103 }104 105 return cbChars;106 }107 108 RTDECL(ssize_t) RTStrPrintf2V(char *pszBuffer, size_t cchBuffer, const char *pszFormat, va_list args)109 {110 STRPRINTF2OUTPUTARGS Args;111 size_t cchRet;112 AssertMsg(cchBuffer > 0, ("Excellent idea! Format a string with no space for the output!\n"));113 114 Args.pszCur = pszBuffer;115 Args.cbLeft = cchBuffer;116 Args.fOverflowed = false;117 118 cchRet = RTStrFormatV(rtStrPrintf2Output, &Args, NULL, NULL, pszFormat, args);119 120 return !Args.fOverflowed ? (ssize_t)cchRet : -(ssize_t)cchRet - 1;121 }122 RT_EXPORT_SYMBOL(RTStrPrintf2V);123 124 125 34 126 35 RTDECL(ssize_t) RTStrPrintf2(char *pszBuffer, size_t cchBuffer, const char *pszFormat, ...) … … 136 45 137 46 138 RTDECL(ssize_t) RTStrPrintf2ExV(PFNSTRFORMAT pfnFormat, void *pvArg, char *pszBuffer, size_t cchBuffer,139 const char *pszFormat, va_list args)140 {141 STRPRINTF2OUTPUTARGS Args;142 size_t cchRet;143 AssertMsg(cchBuffer > 0, ("Excellent idea! Format a string with no space for the output!\n"));144 145 Args.pszCur = pszBuffer;146 Args.cbLeft = cchBuffer;147 Args.fOverflowed = false;148 cchRet = RTStrFormatV(rtStrPrintf2Output, &Args, pfnFormat, pvArg, pszFormat, args);149 return !Args.fOverflowed ? (ssize_t)cchRet : -(ssize_t)cchRet - 1;150 }151 RT_EXPORT_SYMBOL(RTStrPrintf2ExV);152 153 154 47 RTDECL(ssize_t) RTStrPrintf2Ex(PFNSTRFORMAT pfnFormat, void *pvArg, char *pszBuffer, size_t cchBuffer, const char *pszFormat, ...) 155 48 { -
trunk/src/VBox/Runtime/common/string/strprintf2.cpp
r91788 r91789 106 106 } 107 107 108 108 109 RTDECL(ssize_t) RTStrPrintf2V(char *pszBuffer, size_t cchBuffer, const char *pszFormat, va_list args) 109 110 { … … 123 124 124 125 125 126 RTDECL(ssize_t) RTStrPrintf2(char *pszBuffer, size_t cchBuffer, const char *pszFormat, ...)127 {128 va_list va;129 ssize_t cbRet;130 va_start(va, pszFormat);131 cbRet = RTStrPrintf2V(pszBuffer, cchBuffer, pszFormat, va);132 va_end(va);133 return cbRet;134 }135 RT_EXPORT_SYMBOL(RTStrPrintf2);136 137 138 126 RTDECL(ssize_t) RTStrPrintf2ExV(PFNSTRFORMAT pfnFormat, void *pvArg, char *pszBuffer, size_t cchBuffer, 139 127 const char *pszFormat, va_list args) … … 151 139 RT_EXPORT_SYMBOL(RTStrPrintf2ExV); 152 140 153 154 RTDECL(ssize_t) RTStrPrintf2Ex(PFNSTRFORMAT pfnFormat, void *pvArg, char *pszBuffer, size_t cchBuffer, const char *pszFormat, ...)155 {156 va_list args;157 ssize_t cbRet;158 va_start(args, pszFormat);159 cbRet = RTStrPrintf2ExV(pfnFormat, pvArg, pszBuffer, cchBuffer, pszFormat, args);160 va_end(args);161 return cbRet;162 }163 RT_EXPORT_SYMBOL(RTStrPrintf2Ex);164 -
trunk/src/VBox/VMM/VMMR0/VMMR0.def
r90997 r91789 43 43 RTLogLoggerEx 44 44 RTLogLoggerExV 45 RTStrPrintf 45 46 RTTimeMilliTS 46 47 RTTraceBufAddMsgF
Note:
See TracChangeset
for help on using the changeset viewer.