Changeset 49039 in vbox for trunk/src/VBox/Additions/common/VBoxService
- Timestamp:
- Oct 10, 2013 6:27:32 PM (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Additions/common/VBoxService/VBoxServiceControlSession.cpp
r48775 r49039 1742 1742 if (pszLogFile) 1743 1743 { 1744 char *pszLog Ext= NULL;1745 if (RTPathHas Ext(pszLogFile))1746 pszLog Ext = RTStrDup(RTPathExt(pszLogFile));1747 RTPathStrip Ext(pszLogFile);1748 char *pszLog Suffix;1744 char *pszLogSuff = NULL; 1745 if (RTPathHasSuffix(pszLogFile)) 1746 pszLogSuff = RTStrDup(RTPathSuffix(pszLogFile)); 1747 RTPathStripSuffix(pszLogFile); 1748 char *pszLogNewSuffix; 1749 1749 #ifndef DEBUG 1750 if (RTStrAPrintf(&pszLog Suffix, "-%RU32-%s",1750 if (RTStrAPrintf(&pszLogNewSuffix, "-%RU32-%s", 1751 1751 pSessionStartupInfo->uSessionID, 1752 1752 pSessionStartupInfo->szUser) < 0) … … 1755 1755 } 1756 1756 #else 1757 if (RTStrAPrintf(&pszLog Suffix, "-%RU32-%RU32-%s",1757 if (RTStrAPrintf(&pszLogNewSuffix, "-%RU32-%RU32-%s", 1758 1758 pSessionStartupInfo->uSessionID, 1759 1759 s_uCtrlSessionThread, … … 1765 1765 else 1766 1766 { 1767 rc2 = RTStrAAppend(&pszLogFile, pszLog Suffix);1768 if (RT_SUCCESS(rc2) && pszLog Ext)1769 rc2 = RTStrAAppend(&pszLogFile, pszLog Ext);1767 rc2 = RTStrAAppend(&pszLogFile, pszLogNewSuffix); 1768 if (RT_SUCCESS(rc2) && pszLogSuff) 1769 rc2 = RTStrAAppend(&pszLogFile, pszLogSuff); 1770 1770 if (RT_SUCCESS(rc2)) 1771 1771 { … … 1776 1776 } 1777 1777 } 1778 RTStrFree(pszLog Suffix);1778 RTStrFree(pszLogNewSuffix); 1779 1779 } 1780 1780 if (RT_FAILURE(rc2)) 1781 1781 VBoxServiceError("Error building session logfile string for session %RU32 (user %s), rc=%Rrc\n", 1782 1782 pSessionStartupInfo->uSessionID, pSessionStartupInfo->szUser, rc2); 1783 if (pszLog Ext)1784 RTStrFree(pszLog Ext);1783 if (pszLogSuff) 1784 RTStrFree(pszLogSuff); 1785 1785 RTStrFree(pszLogFile); 1786 1786 }
Note:
See TracChangeset
for help on using the changeset viewer.