Hi,

I made simple test program using the subprocess module (see attached:
exec_cmd.py). I ran it passing variations of 'ls' command options.

I encounter exceptions every time I use '-l' options. Example runs
where exception occurs:
# ./exec_cmd.py ls -al
# ./exec_cmd.py ls -l

However, if I pass 'ls' and arguments as one argument, like so:
#./exec_cmd.py 'ls -al'
exception does not occur.

I logged output (see ls_test.out).

So, what could be causing this behavior? Is this expected or is there
something wrong with how I'm using the subprocess module?

Cheers,
Earl

-- 
There are seven words in this sentence.

Attachment: exec_cmd.py
Description: Binary data

Attachment: ls-test.out
Description: Binary data

-- 
https://mail.python.org/mailman/listinfo/python-list

Reply via email to