From a60055974e44f86fe1f880ba0d28b6f72201832f Mon Sep 17 00:00:00 2001
From: toole1 <toole1@6fbd10e7-183d-0410-a318-cb416676e4f2>
Date: Sat, 23 Jul 2011 06:37:35 +0000
Subject: [PATCH] jack

git-svn-id: https://subversion.cs.illinois.edu/svn/cs225@3381 6fbd10e7-183d-0410-a318-cb416676e4f2
---
 proxy.cpp | 8 ++------
 1 file changed, 2 insertions(+), 6 deletions(-)

diff --git a/proxy.cpp b/proxy.cpp
index f6bc86a..4356201 100755
--- a/proxy.cpp
+++ b/proxy.cpp
@@ -471,6 +471,7 @@ bool fork_execute(F & executor)
 	// Fork
 	pid_t process_id;
 	process_id = fork();
+	EXIT_IF_ERROR(process_id < 0, "Could not fork application");
 
 	if (process_id == 0)
 	{
@@ -480,7 +481,7 @@ bool fork_execute(F & executor)
 		// (which is important if we use valgrind ./proxy recursively)
 		return false; // previously exit(0);
 	}
-	else if (process_id > 0)
+	else // if (process_id > 0)
 	{
 		executor.parent();
 
@@ -497,11 +498,6 @@ bool fork_execute(F & executor)
 
 		return true;
 	}
-	else // if (process_id < 0)
-	{
-		perror("Abort: " __FILE__ ":" STR(__LINE__));
-		exit(-1);
-	}
 }
 
 
-- 
GitLab