diff options
author | runge <runge@karlrunge.com> | 2010-12-21 12:04:02 -0500 |
---|---|---|
committer | runge <runge@karlrunge.com> | 2010-12-21 12:04:02 -0500 |
commit | 365a22c63cb292ea494f39ebc48a37e322e5eb14 (patch) | |
tree | ca6e87ab396ee00a837b09b2c6cede62aec69dae /x11vnc/unixpw.c | |
parent | d4fabc217e8cd02aca4d248229bb8a030b2bbfe2 (diff) | |
download | libtdevnc-365a22c63cb292ea494f39ebc48a37e322e5eb14.tar.gz libtdevnc-365a22c63cb292ea494f39ebc48a37e322e5eb14.zip |
x11vnc: touchscreen uinput support and Java viewer mousewheel support. See x11vnc/ChangeLog for rest.
Diffstat (limited to 'x11vnc/unixpw.c')
-rw-r--r-- | x11vnc/unixpw.c | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/x11vnc/unixpw.c b/x11vnc/unixpw.c index b610fa9..ccdb195 100644 --- a/x11vnc/unixpw.c +++ b/x11vnc/unixpw.c @@ -565,6 +565,12 @@ char *get_pty_ptmx(int *fd_p) { ioctl(fd, TIOCFLUSH, (char *) 0); #endif + if (strlen(slave) > sizeof(slave_str)/2) { + rfbLog("get_pty_ptmx: slave string length too long.\n"); + close(fd); + return NULL; + } + strcpy(slave_str, slave); *fd_p = fd; return slave_str; @@ -1743,7 +1749,7 @@ void unixpw_keystroke(rfbBool down, rfbKeySym keysym, int init) { down ? "down":"up ", keysym, keystr); } - if (keysym == XK_Return || keysym == XK_Linefeed) { + if (keysym == XK_Return || keysym == XK_Linefeed || keysym == XK_Tab) { /* let "up" pass down below for Return case */ if (down) { return; @@ -1866,7 +1872,7 @@ void unixpw_keystroke(rfbBool down, rfbKeySym keysym, int init) { return; } - if (keysym == XK_Return || keysym == XK_Linefeed) { + if (keysym == XK_Return || keysym == XK_Linefeed || keysym == XK_Tab) { char pw[] = "Password: "; if (down) { |