Changeset 10638 in vbox for trunk/src/VBox
- Timestamp:
- Jul 15, 2008 10:01:32 AM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Additions/common/VBoxGuestLib/VBoxGuestR3LibMisc.cpp
r10626 r10638 55 55 VBGLR3DECL(int) VbglR3WriteLog(const char *pch, size_t cb) 56 56 { 57 #if defined(RT_OS_WINDOWS) /** @todo more OSes could take this route (solaris and freebsd for instance). */58 57 /* 59 * Handle the entire request in one go. 58 * Quietly skip NULL strings. 59 * (Happens in the RTLogBackdoorPrintf case.) 60 60 */ 61 if (! pch || !cb)61 if (!cb) 62 62 return VINF_SUCCESS; 63 if (!VALID_PTR(pch)) 64 return VERR_INVALID_POINTER; 63 65 66 #ifdef RT_OS_WINDOWS 67 /* 68 * Duplicate the string as it may be read only (a C string). 69 */ 64 70 void *pvTmp = RTMemDup(pch, cb); 65 71 if (!pvTmp) … … 68 74 RTMemFree(pvTmp); 69 75 return rc; 76 77 #elif 0 /** @todo Several OSes could take this route (solaris and freebsd for instance). */ 78 /* 79 * Handle the entire request in one go. 80 */ 81 return vbglR3DoIOCtl(VBOXGUEST_IOCTL_LOG(cb), pvTmp, cb); 70 82 71 83 #else
Note:
See TracChangeset
for help on using the changeset viewer.