VirtualBox

Changeset 26244 in vbox for trunk/src/VBox/Devices/EFI


Ignore:
Timestamp:
Feb 4, 2010 5:25:24 PM (15 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
57300
Message:

DevEFI.cpp: Use RTPathAppend instead of RTStrNLen/strcpy.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Devices/EFI/DevEFI.cpp

    r26221 r26244  
    10501050    if (rc == VERR_CFGM_VALUE_NOT_FOUND)
    10511051    {
    1052         pThis->pszEfiRomFile = (char*)PDMDevHlpMMHeapAlloc(pDevIns, RTPATH_MAX);
     1052        pThis->pszEfiRomFile = (char *)PDMDevHlpMMHeapAlloc(pDevIns, RTPATH_MAX);
    10531053        if (!pThis->pszEfiRomFile)
    10541054            return VERR_NO_MEMORY;
    10551055
    1056         rc = RTPathAppPrivateArch(pThis->pszEfiRomFile, RTPATH_MAX - 32);
     1056        rc = RTPathAppPrivateArch(pThis->pszEfiRomFile, RTPATH_MAX);
    10571057        AssertRCReturn(rc, rc);
    1058 
    1059         size_t offFilename = RTStrNLen(pThis->pszEfiRomFile, RTPATH_MAX);
    1060         strcpy(pThis->pszEfiRomFile+offFilename, "/VBoxEFI32.fd");
    1061         rc = VINF_SUCCESS;
     1058        rc = RTPathAppend(pThis->pszEfiRomFile, RTPATH_MAX, "VBoxEFI32.fd");
     1059        AssertRCReturn(rc, rc);
    10621060    }
    10631061    else if (RT_FAILURE(rc))
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