# 37239
r = mkaply@us.ibm.com, a = brendan OS/2 bringup continues on M16 - These files are OS/2 only!
This commit is contained in:
@@ -283,7 +283,7 @@ nsLocalFile::InitWithPath(const char *filePath)
|
||||
if(temp[len] == '\\')
|
||||
temp[len] = '\0';
|
||||
|
||||
mPath.SetString(nativeFilePath);
|
||||
mPath.Assign(nativeFilePath);
|
||||
nsAllocator::Free( nativeFilePath );
|
||||
return NS_OK;
|
||||
}
|
||||
@@ -431,6 +431,20 @@ nsLocalFile::Append(const char *node)
|
||||
#endif
|
||||
}
|
||||
|
||||
NS_IMETHODIMP
|
||||
nsLocalFile::AppendRelativePath(const char *node)
|
||||
{
|
||||
// Cannot start with a / or have .. or have / anywhere
|
||||
if (!node || (*node == '/') || (strstr(node, "..") != nsnull) ||
|
||||
(strchr(node, '/') != nsnull))
|
||||
{
|
||||
return NS_ERROR_FILE_UNRECOGNIZED_PATH;
|
||||
}
|
||||
mPath.Append("\\");
|
||||
mPath.Append(node);
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
NS_IMETHODIMP
|
||||
nsLocalFile::Normalize()
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user