aboutsummaryrefslogtreecommitdiff
path: root/tests/unistd/truncate.c
diff options
context:
space:
mode:
Diffstat (limited to 'tests/unistd/truncate.c')
-rw-r--r--tests/unistd/truncate.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/tests/unistd/truncate.c b/tests/unistd/truncate.c
index e63a4c13..5620f502 100644
--- a/tests/unistd/truncate.c
+++ b/tests/unistd/truncate.c
@@ -76,5 +76,11 @@ int main() {
memset(&s, 0, sizeof s);
errno = 0;
+ // Restore full permissions on all created files so that python test runner rmtree
+ // won't have problems on deleting the files. On Windows, calling shutil.rmtree()
+ // will fail if any of the files are read-only.
+ EM_ASM(
+ FS.chmod('toread', 0777);
+ );
return 0;
}