Commit ff537b32 authored by Gaute Hope's avatar Gaute Hope

minor..

svn path=/trunk/; revision=1099
parent afe89dc8
2008-10-01 Gaute Hope <eg@gaute.vetsj.com>
* Cleaned up the run function a bit more.. problem persists - can't take care of differencies between shells that don't act like they should.
2008-09-28 Gaute Hope <eg@gaute.vetsj.com>
* Attempt to fix bug 552964, rewrote 'run script' functions. deleting temporary files.
......
......@@ -701,21 +701,25 @@ class main:
elif self.schedule.get_type () == "crontab":
script = self.schedule.parse (commands)[1][5]
script = script + "\necho " + _("Press ENTER to continue and close this window.") + "\n"
# left untranslated to protect against any 'translation attacks'..
script = script + "\necho " + "Press ENTER to continue and close this window." + "\n"
script = script + "read\nexit\n"
tmp.write (script)
tmp.flush ()
self.temp_files.append ((tmp, path))
execute = self.user_shell + " " + path
if self.root == 1:
if self.user != "root":
execute = "su " + self.user + " -c \"" + self.user_shell + " " + path
os.chown (path, self.uid, self.gid)
os.chmod (path, stat.S_IEXEC | stat.S_IREAD)
tmp.flush ()
gnome.execute_terminal_shell_fds (self.user_home_dir, execute, True)
self.temp_files.append ((tmp, path))
gnome.execute_terminal_shell (self.user_home_dir, execute)
except Exception, ex:
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment