VirtualBox

Changeset 85233 in vbox


Ignore:
Timestamp:
Jul 11, 2020 4:30:55 PM (4 years ago)
Author:
vboxsync
Message:

Main/ExtPackUtil.cpp: Fixed a error string construction bug in VBoxExtPackLoadDesc, simplified the others. bugref:9790

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Main/src-all/ExtPackUtil.cpp

    r82968 r85233  
    251251    int vrc = RTPathJoin(szFilePath, sizeof(szFilePath), a_pszDir, VBOX_EXTPACK_DESCRIPTION_NAME);
    252252    if (RT_FAILURE(vrc))
    253         return new RTCString("RTPathJoin failed with %Rrc", vrc);
     253        return new RTCStringFmt("RTPathJoin failed with %Rrc", vrc);
    254254
    255255    RTFSOBJINFO ObjInfo;
    256256    vrc = RTPathQueryInfoEx(szFilePath, &ObjInfo,  RTFSOBJATTRADD_UNIX, RTPATH_F_ON_LINK);
    257257    if (RT_FAILURE(vrc))
    258         return &(new RTCString())->printf("RTPathQueryInfoEx failed with %Rrc", vrc);
     258        return new RTCStringFmt("RTPathQueryInfoEx failed with %Rrc", vrc);
    259259    if (a_pObjInfo)
    260260        *a_pObjInfo = ObjInfo;
     
    263263        if (RTFS_IS_SYMLINK(ObjInfo.Attr.fMode))
    264264            return new RTCString("The XML file is symlinked, that is not allowed");
    265         return &(new RTCString)->printf("The XML file is not a file (fMode=%#x)", ObjInfo.Attr.fMode);
     265        return new RTCStringFmt("The XML file is not a file (fMode=%#x)", ObjInfo.Attr.fMode);
    266266    }
    267267
Note: See TracChangeset for help on using the changeset viewer.

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