diff options
author | Theo de Raadt <deraadt@cvs.openbsd.org> | 2015-11-11 01:12:11 +0000 |
---|---|---|
committer | Theo de Raadt <deraadt@cvs.openbsd.org> | 2015-11-11 01:12:11 +0000 |
commit | df8ebf4c4a153005ea56888d82e05288c597b4dc (patch) | |
tree | c0eb870a47c4f73e3880ed05eb2ca1d61294ea89 /games/mille/save.c | |
parent | 4a35cd787d4211704bc33e641f746562a95af113 (diff) |
creat() -> open equiv; from Frederic Nowak
Diffstat (limited to 'games/mille/save.c')
-rw-r--r-- | games/mille/save.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/games/mille/save.c b/games/mille/save.c index 9d44ca32580..b699fe3bfb8 100644 --- a/games/mille/save.c +++ b/games/mille/save.c @@ -1,4 +1,4 @@ -/* $OpenBSD: save.c,v 1.8 2009/10/27 23:59:26 deraadt Exp $ */ +/* $OpenBSD: save.c,v 1.9 2015/11/11 01:12:10 deraadt Exp $ */ /* $NetBSD: save.c,v 1.4 1995/03/24 05:02:13 cgd Exp $ */ /* @@ -100,7 +100,7 @@ over: && getyn(OVERWRITEFILEPROMPT) == FALSE)) return FALSE; - if ((outf = creat(buf, 0644)) < 0) { + if ((outf = open(buf, O_CREAT | O_TRUNC | O_WRONLY, 0644)) < 0) { error(strerror(errno)); return FALSE; } |