]> gitweb.factorcode.org Git - factor.git/commitdiff
wipe.windows: use normalize-path so resource:foo.txt works
authorJohn Benediktsson <mrjbq7@gmail.com>
Wed, 23 Aug 2023 15:59:14 +0000 (08:59 -0700)
committerJohn Benediktsson <mrjbq7@gmail.com>
Wed, 23 Aug 2023 15:59:14 +0000 (08:59 -0700)
extra/wipe/windows/windows.factor

index c13f7a802b25ce8c3f38d1e3af4a24b88d87d6d3..5f9a7dc7c8899195bf1b235fd0ff262891f424e1 100644 (file)
@@ -1,11 +1,13 @@
 ! Copyright (C) 2023 Alexander Ilin.
 ! See https://factorcode.org/license.txt for BSD license.
-USING: io.files.windows kernel math system windows.kernel32 wipe ;
+USING: io.backend io.files.windows kernel math system
+windows.kernel32 wipe ;
 IN: wipe.windows
 
 : extract-bit ( n mask -- n' ? )
     [ bitnot bitand ] [ bitand 0 = not ] bi-curry bi ; inline
 
 M: windows remove-read-only
-    dup GetFileAttributesW FILE_ATTRIBUTE_READONLY extract-bit
+    normalize-path dup GetFileAttributesW
+    FILE_ATTRIBUTE_READONLY extract-bit
     [ set-file-attributes ] [ 2drop ] if ;