Patrick Williams | b48b7b4 | 2016-08-17 15:04:38 -0500 | [diff] [blame^] | 1 | Fix error found with "-Werror=format-security" flag |
| 2 | |
| 3 | Patch borrowed from Fedora |
| 4 | |
| 5 | Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> |
| 6 | |
| 7 | Upstream-Status: Pending |
| 8 | |
| 9 | diff -Naur imap-2007f.orig/src/osdep/unix/flocklnx.c imap-2007f/src/osdep/unix/flocklnx.c |
| 10 | --- imap-2007f.orig/src/osdep/unix/flocklnx.c 2011-07-23 02:20:11.000000000 +0200 |
| 11 | +++ imap-2007f/src/osdep/unix/flocklnx.c 2014-04-14 19:17:46.429000000 +0200 |
| 12 | @@ -57,7 +57,7 @@ |
| 13 | case ENOLCK: /* lock table is full */ |
| 14 | sprintf (tmp,"File locking failure: %s",strerror (errno)); |
| 15 | mm_log (tmp,WARN); /* give the user a warning of what happened */ |
| 16 | - if (!logged++) syslog (LOG_ERR,tmp); |
| 17 | + if (!logged++) syslog (LOG_ERR, "%s", tmp); |
| 18 | /* return failure if non-blocking lock */ |
| 19 | if (op & LOCK_NB) return -1; |
| 20 | sleep (5); /* slow down in case it loops */ |