From 0841aaf3a09b4ddcf5ea52a6c781f5e11cf85227 Mon Sep 17 00:00:00 2001 From: Siri Hansen Date: Tue, 19 Mar 2013 14:32:02 +0100 Subject: [sasl] Quote path to program run with open_port({spawn,... This is to allow space in the path. --- lib/sasl/src/erlsrv.erl | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'lib/sasl/src/erlsrv.erl') diff --git a/lib/sasl/src/erlsrv.erl b/lib/sasl/src/erlsrv.erl index 086dc7c651..58d43cda34 100644 --- a/lib/sasl/src/erlsrv.erl +++ b/lib/sasl/src/erlsrv.erl @@ -1,7 +1,7 @@ %% %% %CopyrightBegin% %% -%% Copyright Ericsson AB 1998-2011. All Rights Reserved. +%% Copyright Ericsson AB 1998-2013. All Rights Reserved. %% %% The contents of this file are subject to the Erlang Public License, %% Version 1.1, (the "License"); you may not use this file except in @@ -39,7 +39,7 @@ current_version() -> run_erlsrv(Command) -> run_erlsrv(current_version(),Command). run_erlsrv(EVer, Command) -> - case catch(open_port({spawn, erlsrv(EVer) ++ " " ++ Command}, + case catch(open_port({spawn, "\"" ++ erlsrv(EVer) ++ "\" " ++ Command}, [{line,1000}, in, eof])) of {'EXIT',{Reason,_}} -> {port_error, Reason}; @@ -53,7 +53,7 @@ run_erlsrv(EVer, Command) -> end. run_erlsrv_interactive(EVer, Commands) -> - case catch(open_port({spawn, erlsrv(EVer) ++ " readargs"}, + case catch(open_port({spawn, "\""++ erlsrv(EVer) ++ "\" readargs"}, [{line,1000}, eof])) of {'EXIT',{Reason,_}} -> {port_error, Reason}; -- cgit v1.2.3