1
0
mirror of https://github.com/gryf/wicd.git synced 2025-12-19 20:38:00 +01:00
Files
wicd/run-script.py
imdano 197f6913af Added a bunch of bug fixes from the experimental branch to the testing branch.
Added disconnect script feature and executing script in usermode feature to testing branch
2007-08-15 07:25:10 +00:00

17 lines
350 B
Python
Executable File

#!/usr/bin/python
##
#Simple script that converts command line args to a string and executes it in usermode
##
import os,sys,misc
print 'executing script in user mode'
os.setuid(1000)
command = ''
for stuff in sys.argv[1:]:
command = command + ' ' + stuff
print 'command = ',command
pid = os.fork()
print 'hey'
if not pid:
misc.Run(command)