Skip to content

Commit ea2ea44

Browse files
committed
Added multi-file support to PE95TIME.LUA.
1 parent 49b5023 commit ea2ea44

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

demo/xtra/PE95TIME.LUA

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
#!/usr/bin/env lua
1+
#!/usr/bin/env lua
22

33
I,X,V,H="<I4",0x80000000,809222400,[[This script edits timestamps in a PE formatted EXE to the Windows 95 release date.
44
This allows repeatable builds to be verified by checksum tools. Backup the EXE before using this tool on it.]]
@@ -20,4 +20,4 @@ function A(o,l,v)
2020
if(d&X)~=0 then A(d&(X-1),l+1,v or(l==1 and i==16))
2121
elseif v and l==3 then local r=C()S(K+d)B(R(4),R(4))S(r)end end end
2222
if #arg<1 then print(arg[0],"'PEFORMAT.EXE'\n\n"..H)os.exit(1)end
23-
F=assert(io.open(arg[1],"r+b"))J=P()W(J+8,V)O()A(0,1)F:close()print("OK")
23+
for _,v in ipairs(arg)do io.write(v..": ")F=assert(io.open(v,"r+b"))J=P()W(J+8,V)O()A(0,1)F:close()print("OK")end

0 commit comments

Comments
 (0)