diff options
author | runge <runge> | 2008-09-14 19:28:25 +0000 |
---|---|---|
committer | runge <runge> | 2008-09-14 19:28:25 +0000 |
commit | 95d7788eb062a6c6ba07bee516e4e8f1cc8a4db4 (patch) | |
tree | 37da2bfec58413d02c9fbe59f86e848bf0fec348 /x11vnc/tkx11vnc | |
parent | d5cba7a574a667f5321194cb05d0b4adcb995866 (diff) | |
download | libtdevnc-95d7788eb062a6c6ba07bee516e4e8f1cc8a4db4.tar.gz libtdevnc-95d7788eb062a6c6ba07bee516e4e8f1cc8a4db4.zip |
x11vnc: -sleepin m-n for random sleep. More mktemp and mkstemp
protections. SSL_INIT_TIMEOUT=n env. var. Fix macosx console
X call bug. Synchronize other projects sources.
Diffstat (limited to 'x11vnc/tkx11vnc')
-rwxr-xr-x | x11vnc/tkx11vnc | 15 |
1 files changed, 11 insertions, 4 deletions
diff --git a/x11vnc/tkx11vnc b/x11vnc/tkx11vnc index 6fc846e..4260d27 100755 --- a/x11vnc/tkx11vnc +++ b/x11vnc/tkx11vnc @@ -6275,10 +6275,17 @@ proc restart_everything {gui_mode} { exit 1; } set tmp "/tmp/x11vnc[pid]" - file delete -force $tmp - if {[file exists $tmp]} { - puts stderr "failure in restart_everything." - exit 1; + append tmp [clock clicks] + set tmp2 "" + catch {set tmp2 [exec mktemp $tmp.XXXXXX 2>/dev/null]} + if {$tmp2 != "" && [file exists $tmp2]} { + set tmp $tmp2 + } else { + file delete -force $tmp + if {[file exists $tmp]} { + puts stderr "failure in restart_everything." + exit 1; + } } set fh [open $tmp "a"] if {![file owned $tmp]} { |