pathhost-darwin.cpp revision 3490d4bf2a8a1834a93809283876d4ec7077ec80
3490d4bf2a8a1834a93809283876d4ec7077ec80vboxsync * IPRT - Path Convertions, Darwin.
3490d4bf2a8a1834a93809283876d4ec7077ec80vboxsync * On darwin path names on the disk are decomposed using normalization
3490d4bf2a8a1834a93809283876d4ec7077ec80vboxsync * form D (NFD). Since this behavior is unique for the Mac, we will precompose
3490d4bf2a8a1834a93809283876d4ec7077ec80vboxsync * the path name strings we get from the XNU kernel.
3490d4bf2a8a1834a93809283876d4ec7077ec80vboxsync * Copyright (C) 2006-2010 Oracle Corporation
3490d4bf2a8a1834a93809283876d4ec7077ec80vboxsync * This file is part of VirtualBox Open Source Edition (OSE), as
3490d4bf2a8a1834a93809283876d4ec7077ec80vboxsync * available from http://www.virtualbox.org. This file is free software;
3490d4bf2a8a1834a93809283876d4ec7077ec80vboxsync * you can redistribute it and/or modify it under the terms of the GNU
3490d4bf2a8a1834a93809283876d4ec7077ec80vboxsync * General Public License (GPL) as published by the Free Software
3490d4bf2a8a1834a93809283876d4ec7077ec80vboxsync * Foundation, in version 2 as it comes in the "COPYING" file of the
3490d4bf2a8a1834a93809283876d4ec7077ec80vboxsync * VirtualBox OSE distribution. VirtualBox OSE is distributed in the
3490d4bf2a8a1834a93809283876d4ec7077ec80vboxsync * hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
3490d4bf2a8a1834a93809283876d4ec7077ec80vboxsync * The contents of this file may alternatively be used under the terms
3490d4bf2a8a1834a93809283876d4ec7077ec80vboxsync * of the Common Development and Distribution License Version 1.0
3490d4bf2a8a1834a93809283876d4ec7077ec80vboxsync * (CDDL) only, as it comes in the "COPYING.CDDL" file of the
3490d4bf2a8a1834a93809283876d4ec7077ec80vboxsync * VirtualBox OSE distribution, in which case the provisions of the
3490d4bf2a8a1834a93809283876d4ec7077ec80vboxsync * CDDL are applicable instead of those of the GPL.
3490d4bf2a8a1834a93809283876d4ec7077ec80vboxsync * You may elect to license modified versions of this file under the
3490d4bf2a8a1834a93809283876d4ec7077ec80vboxsync * terms and conditions of either the GPL or the CDDL or both.
3490d4bf2a8a1834a93809283876d4ec7077ec80vboxsync/*******************************************************************************
3490d4bf2a8a1834a93809283876d4ec7077ec80vboxsync* Header Files *
3490d4bf2a8a1834a93809283876d4ec7077ec80vboxsync*******************************************************************************/
3490d4bf2a8a1834a93809283876d4ec7077ec80vboxsyncint rtPathToNative(char **ppszNativePath, const char *pszPath)
3490d4bf2a8a1834a93809283876d4ec7077ec80vboxsync /** @todo We should decompose the string here, but the file system will do
3490d4bf2a8a1834a93809283876d4ec7077ec80vboxsync * that for us if we don't, so why bother. */
3490d4bf2a8a1834a93809283876d4ec7077ec80vboxsyncint rtPathToNativeEx(char **ppszNativePath, const char *pszPath, const char *pszBasePath)
3490d4bf2a8a1834a93809283876d4ec7077ec80vboxsyncvoid rtPathFreeNative(char *pszNativePath, const char *pszPath)
3490d4bf2a8a1834a93809283876d4ec7077ec80vboxsync Assert((const char *)pszNativePath == pszPath || !pszNativePath);
3490d4bf2a8a1834a93809283876d4ec7077ec80vboxsyncint rtPathFromNative(char **pszPath, const char *pszNativePath)
3490d4bf2a8a1834a93809283876d4ec7077ec80vboxsync /** @todo We must compose the codepoints in the string here. We get file names
3490d4bf2a8a1834a93809283876d4ec7077ec80vboxsync * in normalization form D so we'll end up with normalization form C
3490d4bf2a8a1834a93809283876d4ec7077ec80vboxsync * whatever approach we take. */
3490d4bf2a8a1834a93809283876d4ec7077ec80vboxsyncint rtPathFromNativeEx(char **pszPath, const char *pszNativePath, const char *pszBasePath)