]> git.ipfire.org Git - thirdparty/plymouth.git/commitdiff
main: log when boot.log fails to open
authorRay Strode <rstrode@redhat.com>
Mon, 27 Jan 2014 17:29:06 +0000 (12:29 -0500)
committerRay Strode <rstrode@redhat.com>
Mon, 27 Jan 2014 17:29:06 +0000 (12:29 -0500)
src/main.c

index 7dbe47cf0b33b84f75c96666fb848cb2d08408fc..b82d2c1510c15d94010284eb8aefd3acdadef653 100644 (file)
@@ -768,8 +768,13 @@ prepare_logging (state_t *state)
   logfile = get_log_file_for_mode (state->mode);
   if (logfile != NULL)
     {
+      bool log_opened;
       ply_trace ("opening log '%s'", logfile);
-      ply_terminal_session_open_log (state->session, logfile);
+
+      log_opened = ply_terminal_session_open_log (state->session, logfile);
+
+      if (!log_opened)
+        ply_trace ("failed to open log: %m");
 
       if (state->number_of_errors > 0)
         spool_error (state);