--
James Hunt
____________________________________
http://upstart.ubuntu.com/cookbook
http://upstart.ubuntu.com/cookbook/upstart_cookbook.pdf
=== modified file 'ChangeLog'
--- ChangeLog	2012-03-16 21:02:13 +0000
+++ ChangeLog	2012-03-16 21:06:11 +0000
@@ -40,6 +40,8 @@
 	    flushed _after_ the parent object has been destroyed.
 	  - log_clear_unflushed(): New function to clear the
 	    log_unflushed_files list by attempting to flush the data to disk.
+	  - log_read_watch(): Set remote_closed for scenarios where
+	    error handler never called. (LP: #935585)
 	* init/log.h:
 	  - Added new Log members: detached, remote_closed and open_errno.
 	  - Updated documentation.

=== modified file 'init/log.c'
--- init/log.c	2012-03-16 21:02:13 +0000
+++ init/log.c	2012-03-16 21:06:11 +0000
@@ -685,6 +685,17 @@
 			break;
 		}
 	}
+
+	/* Job process has ended and we've drained all the data the job
+	 * produced, so remote end must have closed.
+	 *
+	 * This cannot be handled entirely by log_io_error_handler()
+	 * since the job may produce some output prior to disks being
+	 * writeable, then end without producing further output.
+	 * In this scenario the error handler is never called.
+	 *
+	 */
+	log->remote_closed = 1;
 }
 
 /**

-- 
upstart-devel mailing list
[email protected]
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/upstart-devel

Reply via email to