Skip to content

Commit 3d758f5

Browse files
committed
Fix unpacking error on Windows (chmod)
Tried to use chmod on Windows where it's not allowed.
1 parent 637117d commit 3d758f5

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

Assets/PatchKit Patcher/Scripts/AppData/Local/Pack1Unarchiver.cs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,10 @@ private void UnpackRegularFile(Pack1Meta.FileEntry file)
130130
using (var fileWritter = new FileStream(destPath, FileMode.CreateNew))
131131
{
132132
Streams.Copy(gzipStream, fileWritter);
133-
Chmod.SetMode(file.Mode.Substring(3), destPath);
133+
if (Platform.IsPosix())
134+
{
135+
Chmod.SetMode(file.Mode.Substring(3), destPath);
136+
}
134137
}
135138
}
136139
}

0 commit comments

Comments
 (0)