Changeset 61578 in vbox for trunk/src/VBox
- Timestamp:
- Jun 8, 2016 2:09:27 PM (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Debugger/DBGPlugInLinux.cpp
r61572 r61578 420 420 421 421 /** @todo: Try to parse where the single messages start to make use of cMessages. */ 422 memcpy(&pszBuf[0], pbLogBuf, RT_MIN(cbBuf, cbLogBuf)); 422 size_t cchLength = RTStrNLen((const char *)pbLogBuf, cbLogBuf); 423 memcpy(&pszBuf[0], pbLogBuf, RT_MIN(cbBuf, cchLength)); 423 424 424 425 /* Done with the buffer. */ … … 427 428 /* Set return size value. */ 428 429 if (pcbActual) 429 *pcbActual = RT_MIN(cbBuf, c bLogBuf);430 431 return cbBuf <= c bLogBuf ? VINF_SUCCESS : VERR_BUFFER_OVERFLOW;430 *pcbActual = RT_MIN(cbBuf, cchLength); 431 432 return cbBuf <= cchLength ? VERR_BUFFER_OVERFLOW : VINF_SUCCESS; 432 433 } 433 434
Note:
See TracChangeset
for help on using the changeset viewer.