Blob Blame History Raw
2010-05-18  Akira TAGOH  <tagoh@redhat.com>

	* src/factory.c (_watch_im_status_cb): don't restart the process
	if the exit status is 0. (rhbz#573604)

Index: src/factory.c
===================================================================
--- src/factory.c	(リビジョン 392)
+++ src/factory.c	(リビジョン 393)
@@ -422,6 +422,10 @@
 
 		if (WIFEXITED (status)) {
 			g_string_append_printf(status_message, "the status %d", WEXITSTATUS (status));
+			if (WEXITSTATUS (status) == 0) {
+				/* don't restart the process. the process died intentionally */
+				g_hash_table_remove(priv->pid2id, GINT_TO_POINTER (pid));
+			}
 		} else if (WIFSIGNALED (status)) {
 			g_string_append_printf(status_message, "the signal %d", WTERMSIG (status));
 			if (WCOREDUMP (status)) {