]> granicus.if.org Git - sudo/commitdiff
Restore warning when sudoers is unable to update the time stamp file.
authorTodd C. Miller <Todd.Miller@courtesan.com>
Sat, 1 Feb 2014 13:11:29 +0000 (06:11 -0700)
committerTodd C. Miller <Todd.Miller@courtesan.com>
Sat, 1 Feb 2014 13:11:29 +0000 (06:11 -0700)
plugins/sudoers/timestamp.c

index eed1e4f5d43950427a88115e38f37231bfecf332..2d643dff83676a4cb8daf8a56d223ea07c671750 100644 (file)
@@ -180,6 +180,9 @@ found_it:
     if ((size_t)nwritten == sizeof(struct timestamp_entry))
        debug_return_bool(true);
 
+    log_warning(nwritten == -1 ? USE_ERRNO : 0,
+       N_("unable to write to %s"), timestamp_file);
+
     /* Truncate on partial write to be safe. */
     if (nwritten > 0 && old_eof != (off_t)-1) {
        sudo_debug_printf(SUDO_DEBUG_DEBUG|SUDO_DEBUG_LINENO,