gpm/gpm-1.20.1-gpmopen.patch
cvsdist c78d0885e9 auto-import changelog data from gpm-1.20.1-38.src.rpm
Thu Aug 07 2003 Adrian Havill <havill@redhat.com> 1.20.1-38
- Gpm_Open() NULL deref revisited (#101104). Patch by <leonardjo@hetnet.nl>
Wed Jul 30 2003 Adrian Havill <havill@redhat.com> 1.20.1-37
- removed auto-add of repeat with -M (#84310)
Tue Jul 29 2003 Adrian Havill <havill@redhat.com> 1.20.1-36
- fixed grammar typos in the init script (#89109)
- don't deref NULL string in Gpm_Open (#101104)
Wed Jul 02 2003 Adrian Havill <havill@redhat.com> 1.20.1-35
- remove debug output from gpm_report() to prevent spurious debugging msgs
    even when not in debug mode (#98210)
Thu Jun 26 2003 Adrian Havill <havill@redhat.com> 1.20.1-33
- reversed -t and -m params in init script, removed $OPTION
- add doc blurb regarding no auto-repeat with multiple mice
Tue Jun 24 2003 Adrian Havill <havill@redhat.com> 1.20.1-32
- update version
- add -lm for ceil()
- add hltest, mouse-test for all but zSeries
Mon Jun 16 2003 Jakub Jelinek <jakub@redhat.com>
- don't link against -lncurses, instead make wgetch and stdscr weak
    undefined symbols to break library dependency cycle
Thu Jun 12 2003 Elliot Lee <sopwith@redhat.com>
- Remove pam requirement
Wed Jun 04 2003 Elliot Lee <sopwith@redhat.com>
- rebuilt
2004-09-09 05:51:57 +00:00

24 lines
918 B
Diff

diff -pruN gpm-1.20.1/src/lib/liblow.c.orig gpm-1.20.1/src/lib/liblow.c
--- gpm-1.20.1/src/lib/liblow.c.orig 2003-08-03 17:55:00.000000000 +0200
+++ gpm-1.20.1/src/lib/liblow.c 2003-08-03 17:59:49.000000000 +0200
@@ -199,8 +199,6 @@ int Gpm_Open(Gpm_Connect *conn, int flag
Gpm_Stst *new = NULL;
char* sock_name = 0;
- option.consolename = NULL;
-
#if 0
gpm_report(GPM_PR_DEBUG,"VC: %d",flag);
#endif
@@ -259,6 +257,10 @@ int Gpm_Open(Gpm_Connect *conn, int flag
gpm_report(GPM_PR_ERR,"checking tty name failed");
goto err;
}
+ if (option.consolename == NULL) {
+ gpm_report(GPM_PR_ERR,"option.consolename not set");
+ goto err;
+ }
/* do we really need this check ? */
if(strncmp(tty,option.consolename,strlen(option.consolename)-1)
|| !isdigit(tty[strlen(option.consolename)-1])) {