From 57a1a5d0cff890b7b2c862d770ee22cc39ae2f59 Mon Sep 17 00:00:00 2001 From: Jamie Cameron Date: Tue, 9 Oct 2012 16:33:31 -0700 Subject: [PATCH] Use more reliable backquote function to capture output --- init/init-lib.pl | 14 ++------------ 1 file changed, 2 insertions(+), 12 deletions(-) diff --git a/init/init-lib.pl b/init/init-lib.pl index 60b530052..bb89f122b 100755 --- a/init/init-lib.pl +++ b/init/init-lib.pl @@ -1114,13 +1114,8 @@ if ($action_mode eq "init" || $action_mode eq "local") { if (!-x $fn) { return (0, "$fn does not exist"); } - local $temp = &transname(); - &foreign_require("proc", "proc-lib.pl"); - open(TEMP, ">$temp"); - &proc::safe_process_exec_logged("$fn start", 0, 0, TEMP); - close(TEMP); + local $out = &backquote_logged("$fn start 2>&1 $temp"); - &proc::safe_process_exec_logged("$fn stop", 0, 0, TEMP); - close(TEMP); + local $out = &backquote_logged("$fn stop 2>&1