Thank you.
I have one more question to you.
Instead of passing the file I want to pass line by line as input and write
the corresponding output to newline in outputfile.

lines = list(rfile)
subprocess.call(['gcc',pathnew,'-o','x'])
L=list()
for line in lines:
subprocess.call(["./x"], stdin = line, stdout=list())

Iam trying to do it with for loop but Iam getting the below error.

AttributeError: 'str' object has no attribute 'fileno'
Is there any other way to do this. Thanks in advance.

On Thu, Jul 9, 2015 at 4:30 PM, Anthony <[email protected]> wrote:

> Keep in mind that this can be dangerous. An untrusted user can upload
> malicious code and compromise your server. Even an innocent bug could do
> some real damage. Priced with caution.
>
> --
> Resources:
> - http://web2py.com
> - http://web2py.com/book (Documentation)
> - http://github.com/web2py/web2py (Source code)
> - https://code.google.com/p/web2py/issues/list (Report Issues)
> ---
> You received this message because you are subscribed to the Google Groups
> "web2py-users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> For more options, visit https://groups.google.com/d/optout.
>



-- 
Chaitanya Pochampally

-- 
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
--- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to