at/at-3.1.12-nowrap.patch
2010-02-12 12:18:30 +00:00

18 lines
606 B
Diff

diff -up at-3.1.12/at.c.nowrap at-3.1.12/at.c
--- at-3.1.12/at.c.nowrap 2010-02-12 12:48:23.000000000 +0100
+++ at-3.1.12/at.c 2010-02-12 12:51:18.781921727 +0100
@@ -308,9 +308,12 @@ writefile(time_t runtimer, char queue)
if (*ap == ' ')
*ap = '0';
- if (stat(atfile, &statbuf) != 0)
+ if (stat(atfile, &statbuf) != 0) {
if (errno != ENOENT)
perr("Cannot access " ATJOB_DIR);
+ } else {
+ perr("atjob file already exists; bailing");
+ }
/* Create the file. The x bit is only going to be set after it has
* been completely written out, to make sure it is not executed in the