gco / rubyripper

Automatically exported from code.google.com/p/rubyripper
0 stars 0 forks source link

Execute.launch assumes incorrectly that backticks will execute under Bourne shell #479

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
On certain operating systems (e.g. FreeBSD), the default shell used for 
executing backtick-quoted expressions is csh rather than sh or bash.  As a 
result, certain functions involving redirecting stderr into stdout (e.g. 
ScanDiscCdparanoia.getQueryResult) will not run correctly on such systems.

There are two possible solutions, including rewriting Execute.launch to use 
popen3 to automatically merge stderr and stdout such that shell redirection is 
no longer needed in those places it is currently used, and forcing usage of the 
Bourne shell is Execute.launch by wrapping the command with "sh -c".

I've attached a patch which implements the latter option, although the former 
seems to be the better long-term solution.

Original issue reported on code.google.com by comradec...@gmail.com on 16 Oct 2011 at 6:52

Attachments:

GoogleCodeExporter commented 9 years ago
And fixed with commit:
http://code.google.com/p/rubyripper/source/detail?r=3b5e64062660be705abc45d1ad20
71cca0e7a9ff

I agree that a better solution is needed. But one thing at a time. Thanks for 
the patches and the good bug reports by the way.

Original comment by boukewou...@gmail.com on 17 Oct 2011 at 7:19