[PATCH 03/12][user-cr] Add app_restart_args->debug

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Sukadev Bhattiprolu <sukadev@xxxxxxxxxxxxxxxxxx>
Date: Thu, 4 Mar 2010 17:46:31 -0800
Subject: [PATCH 03/12][user-cr] Add app_restart_args->debug

Make 'debug' a field in struct app_restart_args so other callers of
app_restart() can also control the debug output of app_restart().

Signed-off-by: Sukadev Bhattiprolu <sukadev@xxxxxxxxxxxxxxxxxx>
---
 restart.c |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)

diff --git a/restart.c b/restart.c
index 314390c..87fff1e 100644
--- a/restart.c
+++ b/restart.c
@@ -387,6 +387,7 @@ struct app_restart_args {
 	int infd;
 	int klogfd;
 	long warn;
+	int debug;
 	long fail;
 	int keep_lsm;
 };
@@ -583,7 +584,7 @@ static void parse_args(struct app_restart_args *args, int argc, char *argv[])
 			args->copy_status = 1;
 			break;
 		case 'd':
-			global_debug = 1;
+			global_debug = args->debug = 1;
 			break;
 		case 'F':
 			args->freezer = optarg;
@@ -818,6 +819,7 @@ int app_restart(struct app_restart_args *args)
 	ctx.args = args;
 
 	global_send_sigint = args->send_sigint;
+	global_debug = args->debug;
 
 	/* input file descriptor (default: stdin) */
 	if (args->infd >= 0) {
-- 
1.6.0.4

_______________________________________________
Containers mailing list
Containers@xxxxxxxxxxxxxxxxxxxxxxxxxx
https://lists.linux-foundation.org/mailman/listinfo/containers

[Index of Archives]     [Cgroups]     [Netdev]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite Forum]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux