VirtualBox

Changeset 33439 in vbox for trunk/src/VBox/HostServices


Ignore:
Timestamp:
Oct 25, 2010 7:35:58 PM (14 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
67029
Message:

IPRT, Linux additions, Shared folders: added support for guest shared folder (thanks Brian Campbell)

Location:
trunk/src/VBox/HostServices/SharedFolders
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/HostServices/SharedFolders/service.cpp

    r33409 r33439  
    10501050                {
    10511051                    /* Execute the function. */
    1052 
    10531052                    rc = vbsfRemove (pClient, root, pPath, cbPath, flags);
    10541053                    if (RT_SUCCESS(rc))
  • trunk/src/VBox/HostServices/SharedFolders/vbsf.cpp

    r33409 r33439  
    2828#include <iprt/path.h>
    2929#include <iprt/string.h>
     30#include <iprt/symlink.h>
    3031#include <iprt/uni.h>
    3132#include <iprt/stream.h>
     
    16751676    if (RT_SUCCESS (rc))
    16761677    {
    1677         rc = RTReadLink(pszFullPath, (char *) pBuffer, cbBuffer);
     1678        rc = RTSymlinkRead(pszFullPath, (char *) pBuffer, cbBuffer);
    16781679
    16791680        /* free the path string */
     
    20412042
    20422043    /* Validate input */
    2043     if (   flags & ~(SHFL_REMOVE_FILE|SHFL_REMOVE_DIR)
     2044    if (   flags & ~(SHFL_REMOVE_FILE|SHFL_REMOVE_DIR|SHFL_REMOVE_SYMLINK)
    20442045        || cbPath == 0
    20452046        || pPath == 0)
     
    20652066        if (RT_SUCCESS (rc))
    20662067        {
    2067             if (flags & SHFL_REMOVE_FILE)
     2068            if (flags & SHFL_REMOVE_SYMLINK)
     2069                rc = RTSymlinkDelete(pszFullPath);
     2070            else if (flags & SHFL_REMOVE_FILE)
    20682071                rc = RTFileDelete(pszFullPath);
    20692072            else
     
    21552158        return rc;
    21562159
    2157     rc = RTSymlink(pszFullNewPath, (const char *)pOldPath->String.utf8);
     2160    rc = RTSymlinkCreate(pszFullNewPath, (const char *)pOldPath->String.utf8, RTSYMLINKTYPE_UNKNOWN);
    21582161    if (RT_SUCCESS (rc))
    21592162        rc = RTPathQueryInfoEx(pszFullNewPath, pInfo, RTFSOBJATTRADD_NOTHING, SHFL_RT_LINK(pClient));
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