mirror of
https://github.com/rapid7/metasploit-framework
synced 2024-11-12 11:52:01 +01:00
Actually, don't really have a good reason for that exception handling anymore. I think.
This commit is contained in:
parent
0eb3b5a49b
commit
608a5586b2
@ -164,12 +164,7 @@ class Metasploit3 < Msf::Post
|
||||
print_status("Creating task: #{taskname}")
|
||||
cmdline = "schtasks.exe /create /tn #{taskname} /tr \"#{cmd}\" /sc monthly /f"
|
||||
# print_debug("Will Execute:\n\t#{cmdline}")
|
||||
begin
|
||||
exec_schtasks(cmdline, "create the task")
|
||||
rescue ::Exception => e
|
||||
print_error(e.to_s)
|
||||
return
|
||||
end
|
||||
exec_schtasks(cmdline, "create the task")
|
||||
|
||||
#
|
||||
# Read the contents of the newly creates task file
|
||||
|
Loading…
Reference in New Issue
Block a user