Changeset 628 in vbox for trunk/src/VBox/Runtime
- Timestamp:
- Feb 5, 2007 11:59:58 AM (18 years ago)
- svn:sync-xref-src-repo-rev:
- 18257
- Location:
- trunk/src/VBox/Runtime
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Runtime/log.cpp
r408 r628 1109 1109 { "buffered", sizeof("buffered" ) - 1, RTLOGFLAGS_BUFFERED, false }, 1110 1110 { "unbuffered", sizeof("unbuffered" ) - 1, RTLOGFLAGS_BUFFERED, true }, 1111 { "usecrlf", sizeof("usecrlf" ) - 1, RTLOGFLAGS_USECRLF, true }, 1112 { "uself", sizeof("uself" ) - 1, RTLOGFLAGS_USECRLF, false }, 1111 1113 { "rel", sizeof("rel" ) - 1, RTLOGFLAGS_REL_TS, false }, 1112 { "abs", sizeof(" rel" ) - 1, RTLOGFLAGS_REL_TS, true },1114 { "abs", sizeof("abs" ) - 1, RTLOGFLAGS_REL_TS, true }, 1113 1115 { "dec", sizeof("dec" ) - 1, RTLOGFLAGS_DECIMAL_TS, false }, 1114 1116 { "hex", sizeof("hex" ) - 1, RTLOGFLAGS_DECIMAL_TS, true }, … … 2053 2055 if (pszNewLine) 2054 2056 { 2055 pLogger->fPendingPrefix = true; 2056 cb = pszNewLine - pachChars + 1; 2057 if (pLogger->fFlags & RTLOGFLAGS_USECRLF) 2058 cb = pszNewLine - pachChars; 2059 else 2060 { 2061 cb = pszNewLine - pachChars + 1; 2062 pLogger->fPendingPrefix = true; 2063 } 2057 2064 } 2058 2065 … … 2064 2071 cbRet += cb; 2065 2072 cbChars -= cb; 2073 2074 if ( pszNewLine 2075 && pLogger->fFlags & RTLOGFLAGS_USECRLF 2076 && pLogger->offScratch + 2 < sizeof(pLogger->achScratch)) 2077 { 2078 memcpy(&pLogger->achScratch[pLogger->offScratch], "\r\n", 2); 2079 pLogger->offScratch += 2; 2080 cbRet++; 2081 cbChars--; 2082 cb++; 2083 pLogger->fPendingPrefix = true; 2084 } 2066 2085 2067 2086 /* done? */ -
trunk/src/VBox/Runtime/logformat.cpp
r1 r628 51 51 * @param pfnOutput Output worker. 52 52 * Called in two ways. Normally with a string an it's length. 53 * For termi ation, it's called with NULL for string, 0 for length.53 * For termination, it's called with NULL for string, 0 for length. 54 54 * @param pvArg Argument to output worker. 55 55 * @param pszFormat Format string. -
trunk/src/VBox/Runtime/strformat.cpp
r1 r628 291 291 * @param pfnOutput Output worker. 292 292 * Called in two ways. Normally with a string an it's length. 293 * For termi ation, it's called with NULL for string, 0 for length.293 * For termination, it's called with NULL for string, 0 for length. 294 294 * @param pvArgOutput Argument to the output worker. 295 295 * @param pfnFormat Custom format worker. … … 818 818 * @param pfnOutput Output worker. 819 819 * Called in two ways. Normally with a string an it's length. 820 * For termi ation, it's called with NULL for string, 0 for length.820 * For termination, it's called with NULL for string, 0 for length. 821 821 * @param pvArgOutput Argument to the output worker. 822 822 * @param pfnFormat Custom format worker.
Note:
See TracChangeset
for help on using the changeset viewer.