Use better system call
parent
f7858bf1a7
commit
e31a144f4d
|
@ -158,14 +158,12 @@ class VncInject
|
||||||
Rex::FileUtils::find_full_path('vncviewer.exe')
|
Rex::FileUtils::find_full_path('vncviewer.exe')
|
||||||
|
|
||||||
if (vnc)
|
if (vnc)
|
||||||
if viewonly
|
args = []
|
||||||
vo = "-viewonly "
|
args.push '-viewonly' if viewonly
|
||||||
else
|
args.push "#{vlhost}::#{vlport}"
|
||||||
vo = ""
|
|
||||||
end
|
|
||||||
|
|
||||||
self.view = framework.threads.spawn("VncViewerWrapper", false) {
|
self.view = framework.threads.spawn("VncViewerWrapper", false) {
|
||||||
system("vncviewer #{vo}#{vlhost}::#{vlport}")
|
system(vnc, *args)
|
||||||
}
|
}
|
||||||
|
|
||||||
return true
|
return true
|
||||||
|
|
Loading…
Reference in New Issue