Skip to content

Commit 1b9400b

Browse files
committed
Fixed setPatchFile call to abort() function.
1 parent afae35b commit 1b9400b

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

xtra/PATCH.LUA

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,11 +9,11 @@ local function patch(p)
99
else local words={}for v in string.gmatch(l,"%S+")do table.insert(words,v)end return words[2]end end
1010
local function setPatchFile(f)
1111
local o,b local function abort()print(e)if o then o:close()end if b then b:close()end return false end
12-
o,e=io.open(f)if not o then return abort end
13-
b,e=io.open(f..".orig","w")if not b then return abort end
12+
o,e=io.open(f)if not o then return abort()end
13+
b,e=io.open(f..".orig","w")if not b then return abort()end
1414
for m in o:lines()do b:write(m..'\n')end o:close()b:close()
15-
o,e=io.open(f,"w")if not o then return abort end
16-
b,e=io.open(f..".orig")if not b then return abort end
15+
o,e=io.open(f,"w")if not o then return abort()end
16+
b,e=io.open(f..".orig")if not b then return abort()end
1717
if of then of:close()end if bf then bf:close()end of=o bf=b return true end
1818
local function writeRemainder()if of then local rest=bf:read("*l")while rest do of:write(rest..'\n')rest=bf:read("*l")end of:close()end bf:close()end
1919
local n=pf:read("*l")while n do

0 commit comments

Comments
 (0)