VirtualBox

Changeset 33492 in vbox for trunk/src/VBox/Runtime/r3


Ignore:
Timestamp:
Oct 27, 2010 11:05:14 AM (14 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
67084
Message:

Guest Copy/Guest Additions: Update.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Runtime/r3/isofs.cpp

    r33466 r33492  
    333333                    break;
    334334
    335                 Assert(pCurRecord->name_len > 0);
     335                Assert(   pCurRecord->name_len  > 0
     336                       && pCurRecord->name_len <= RTISOFS_MAX_STRING_LEN);
    336337                char *pszName = RTStrAlloc(pCurRecord->name_len + 1);
    337338                AssertPtr(pszName);
    338339                Assert(idx + sizeof(RTISOFSDIRRECORD) < cbRead);
    339340                memcpy(pszName, &uBuffer[idx + sizeof(RTISOFSDIRRECORD)], pCurRecord->name_len);
     341                pszName[pCurRecord->name_len] = '\0'; /* Force string termination. */
    340342
    341343                if (   pCurRecord->name_len == 1
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