diff options
author | runge <runge> | 2008-11-05 01:18:29 +0000 |
---|---|---|
committer | runge <runge> | 2008-11-05 01:18:29 +0000 |
commit | 63b98dba790fa9835e970b8502d93258862a9373 (patch) | |
tree | 52b5ba99d6f9fe4b8a818eee16955e5e4e5b50de /x11vnc/cleanup.c | |
parent | cb67ada73b007d5f237a281576f753ec6c15844b (diff) | |
download | libvncserver-63b98dba790fa9835e970b8502d93258862a9373.zip libvncserver-63b98dba790fa9835e970b8502d93258862a9373.tar.gz |
x11vnc: add zeroconf external helpers (avahi-publish and
dns-sd). Alias -zeroconf. Close pipeinput_fh on exit.
Kludge to make -solid work on MacOSX console. Attempt at
cpp macros to disable newer libvncserver interfaces.
Diffstat (limited to 'x11vnc/cleanup.c')
-rw-r--r-- | x11vnc/cleanup.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/x11vnc/cleanup.c b/x11vnc/cleanup.c index 3a584bb..e290977 100644 --- a/x11vnc/cleanup.c +++ b/x11vnc/cleanup.c @@ -30,7 +30,7 @@ XErrorEvent *trapped_xerror_event; int crash_debug = 0; void clean_shm(int quick); -void clean_up_exit (int ret); +void clean_up_exit(int ret); int trap_xerror(Display *d, XErrorEvent *error); int trap_xioerror(Display *d); int trap_getimage_xerror(Display *d, XErrorEvent *error); @@ -110,7 +110,7 @@ static void clean_icon_mode(void) { /* * Normal exiting */ -void clean_up_exit (int ret) { +void clean_up_exit(int ret) { static int depth = 0; exit_flag = 1; @@ -150,6 +150,11 @@ void clean_up_exit (int ret) { } #endif + if (pipeinput_fh != NULL) { + pclose(pipeinput_fh); + pipeinput_fh = NULL; + } + if (! dpy) exit(ret); /* raw_rb hack */ /* X keyboard cleanups */ |