mirror of
https://github.com/Thealexbarney/LibHac.git
synced 2024-11-14 10:49:41 +01:00
Use U8StringBuilder instead of PathBuilder
This commit is contained in:
parent
7b4df4671c
commit
0c6447daac
1 changed files with 6 additions and 8 deletions
|
@ -360,16 +360,14 @@ namespace LibHac.FsService
|
||||||
FsPath fullPath;
|
FsPath fullPath;
|
||||||
unsafe { _ = &fullPath; } // workaround for CS0165
|
unsafe { _ = &fullPath; } // workaround for CS0165
|
||||||
|
|
||||||
var pathBuilder = new PathBuilder(fullPath.Str);
|
var sb = new U8StringBuilder(fullPath.Str);
|
||||||
Result rc = pathBuilder.Append(path);
|
sb.Append(path)
|
||||||
if (rc.IsFailure()) return rc;
|
.Append(new[] { (byte)'d', (byte)'a', (byte)'t', (byte)'a', (byte)'/' });
|
||||||
|
|
||||||
rc = pathBuilder.Append(new[] { (byte)'d', (byte)'a', (byte)'t', (byte)'a', (byte)'/' });
|
if (sb.Overflowed)
|
||||||
if (rc.IsFailure()) return rc;
|
return ResultFs.TooLongPath.Log();
|
||||||
|
|
||||||
pathBuilder.Terminate();
|
Result rc = FsCreators.TargetManagerFileSystemCreator.GetCaseSensitivePath(out bool success, fullPath.Str);
|
||||||
|
|
||||||
rc = FsCreators.TargetManagerFileSystemCreator.GetCaseSensitivePath(out bool success, fullPath.Str);
|
|
||||||
if (rc.IsFailure()) return rc;
|
if (rc.IsFailure()) return rc;
|
||||||
|
|
||||||
// Reopen the host filesystem as case sensitive
|
// Reopen the host filesystem as case sensitive
|
||||||
|
|
Loading…
Reference in a new issue