Changeset 28915 in vbox for trunk/src/VBox/Runtime/generic/pathhost-generic.cpp
- Timestamp:
- Apr 29, 2010 6:12:35 PM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Runtime/generic/pathhost-generic.cpp
r28912 r28915 37 37 38 38 39 int rtPathToNative(char **ppszNativePath, const char *pszPath)39 int rtPathToNative(char const **ppszNativePath, const char *pszPath, const char *pszBasePath) 40 40 { 41 *ppszNativePath = (char *)pszPath; 41 *ppszNativePath = pszPath; 42 NOREF(pszBasePath); /* We don't query the FS for codeset preferences. */ 42 43 return VINF_SUCCESS; 43 44 } 44 45 45 46 46 int rtPathToNativeEx(char **ppszNativePath, const char *pszPath, const char *pszBasePath) 47 { 48 /* We don't query the FS for codeset preferences yet, so nothing special to do here. */ 49 NOREF(pszBasePath); 50 return rtPathToNative(ppszNativePath, pszPath); 51 } 52 53 54 void rtPathFreeNative(char *pszNativePath, const char *pszPath) 47 void rtPathFreeNative(char const *pszNativePath, const char *pszPath) 55 48 { 56 49 Assert(pszNativePath == pszPath || !pszNativePath); … … 59 52 60 53 61 int rtPathFromNative(c har **ppszPath, const char *pszNativePath)54 int rtPathFromNative(const char **ppszPath, const char *pszNativePath, const char *pszBasePath) 62 55 { 63 56 int rc = RTStrValidateEncodingEx(pszNativePath, RTSTR_MAX, 0 /*fFlags*/); 64 57 if (RT_SUCCESS(rc)) 65 rc = RTStrDupEx(ppszPath, pszNativePath); 58 *ppszPath = pszNativePath; 59 NOREF(pszBasePath); /* We don't query the FS for codeset preferences. */ 66 60 return rc; 67 61 } 68 62 69 63 70 int rtPathFromNativeEx(char **ppszPath, const char *pszNativePath, const char *pszBasePath)64 void rtPathFreeIprt(const char *pszPath, const char *pszNativePath) 71 65 { 72 /* We don't query the FS for codeset preferences yet, so nothing special to do here. */ 73 NOREF(pszBasePath); 74 return rtPathFromNative(ppszPath, pszNativePath); 66 Assert(pszPath == pszNativePath || !pszPath); 67 NOREF(pszPath); NOREF(pszNativePath); 75 68 } 76 69 70 71 int rtPathFromNativeCopy(char *pszPath, size_t cbPath, const char *pszNativePath, const char *pszBasePath) 72 { 73 int rc = RTStrValidateEncodingEx(pszNativePath, RTSTR_MAX, 0 /*fFlags*/); 74 if (RT_SUCCESS(rc)) 75 rc = RTStrCopyEx(pszPath, cbPath, pszNativePath, RTSTR_MAX); 76 NOREF(pszBasePath); /* We don't query the FS for codeset preferences. */ 77 return rc; 78 } 79
Note:
See TracChangeset
for help on using the changeset viewer.