VirtualBox

Changeset 72944 in vbox for trunk/src/VBox/Main/glue


Ignore:
Timestamp:
Jul 7, 2018 3:27:11 PM (7 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
123496
Message:

GluePrintErrorContext: In fact, don't make any copy of anything here. RTMsgError does an excellent job deal without out-of-memory and similar mishaps, Utf8Str doesn't.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Main/glue/errorprint.cpp

    r72943 r72944  
    8484    // pcszSourceFile comes from __FILE__ macro, which always contains the full path,
    8585    // which we don't want to see printed:
    86     Utf8Str str = Utf8StrFmt("Context: \"%s\" at line %d of file %s\n",
    87                              pcszContext,
    88                              ulLine,
    89                              RTPathFilename(pcszSourceFile));
    9086    // print and log
    91     RTMsgError("%s", str.c_str());
    92     Log(("%s", str.c_str()));
     87    const char *pszFilenameOnly = RTPathFilename(pcszSourceFile);
     88    RTMsgError("Context: \"%s\" at line %d of file %s\n", pcszContext, ulLine, pszFilenameOnly);
     89    Log(("Context: \"%s\" at line %d of file %s\n", pcszContext, ulLine, pszFilenameOnly));
    9390}
    9491
Note: See TracChangeset for help on using the changeset viewer.

© 2025 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette