projects
/
apps
/
madmutt.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
5132171
)
unlink file before writing it, and don't fail if it's not here
author
Pierre Habouzit
<madcoder@debian.org>
Sun, 20 May 2007 12:31:53 +0000
(14:31 +0200)
committer
Pierre Habouzit
<madcoder@debian.org>
Sun, 20 May 2007 12:31:53 +0000
(14:31 +0200)
Signed-off-by: Pierre Habouzit <madcoder@debian.org>
tools/cpkg2c.mll
patch
|
blob
|
history
diff --git
a/tools/cpkg2c.mll
b/tools/cpkg2c.mll
index
c0a0453
..
129004b
100644
(file)
--- a/
tools/cpkg2c.mll
+++ b/
tools/cpkg2c.mll
@@
-631,7
+631,7
@@
int luaopen_%s(lua_State *L)
let lexbuf = L.from_channel (open_in file) in
let l = (startchunk cLine file lexbuf) in
if Sys.argv.(3) = "-o" then (
-
Unix.unlink Sys.argv.(4
);
+
try Unix.unlink Sys.argv.(4) with _ -> (
);
let ob = open_out_gen [ Open_trunc ; Open_wronly; Open_creat ] 0o444 Sys.argv.(4) in
match Sys.argv.(1) with
| "-h" -> warn ob; do_h ob l; close_out ob