Bug 8070 - kudzu hangs (seg-fault) when probing parallel port
Summary: kudzu hangs (seg-fault) when probing parallel port
Status: CLOSED RAWHIDE
Alias: None
Product: Red Hat Linux
Classification: Retired
Component: kudzu   
(Show other bugs)
Version: 6.1
Hardware: All Linux
medium
medium
Target Milestone: ---
Assignee: Bill Nottingham
QA Contact:
URL:
Whiteboard:
Keywords:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 1999-12-30 18:31 UTC by gio
Modified: 2014-03-17 02:11 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 1999-12-30 18:34:54 UTC
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

Description gio 1999-12-30 18:31:34 UTC
I've installed Red Hat 6.1 after which I've recompiled a linux kernel
version 2.2.13 with parallel port support built-in. After that
kudzu has begun to hang with a segmentation-fault (because mfr is NULL);
I've patched it and now it seems working properly. I hope this helps.

Giovanni Lagorio (gio@libertyline.com)

*** parallel.c-orig	Thu Dec 30 14:33:27 1999
--- parallel.c	Thu Dec 30 14:48:03 1999
***************
*** 255,261 ****
  	probebuf=calloc(8192,sizeof(char));
  	bytes=read(lpfile,probebuf,8192);

! 	mfr=model=desc=func=modes=NULL;
  	ptr = probebuf;
  	while (probebuf[0]!='\0') {
  		while (*ptr && *ptr !='\n') ptr++;
--- 255,264 ----
  	probebuf=calloc(8192,sizeof(char));
  	bytes=read(lpfile,probebuf,8192);

! 	mfr=strdup("Unknown vendor") ;
! 	model=strdup("Unknown device") ;
! 	desc=func=modes=NULL ;
!
  	ptr = probebuf;
  	while (probebuf[0]!='\0') {
  		while (*ptr && *ptr !='\n') ptr++;
***************
*** 282,288 ****
  		}
  		probebuf=ptr;
  	}
! 	if (!strcmp(mfr,"Unknown vendor")&&!strcmp(model,"Unknown device"))
return NULL;
  	key.pnpmfr = mfr;
  	key.pnpmodel = model;
  	pardev = bsearch(&key,parallelDeviceList,numParallelDevices,
--- 285,298 ----
  		}
  		probebuf=ptr;
  	}
! 	if (!strcmp(mfr,"Unknown vendor")&&!strcmp(model,"Unknown device")) {
! 		if (mfr) free(mfr);
! 		if (model) free(model);
! 		if (func) free(func);
! 		if (modes) free(modes);
! 		if (desc) free(desc);
! 		return NULL;
! 	}
  	key.pnpmfr = mfr;
  	key.pnpmodel = model;
  	pardev = bsearch(&key,parallelDeviceList,numParallelDevices,

Comment 1 Bill Nottingham 1999-12-30 18:34:59 UTC
This should be fixed in the latest kudzu currently in
Raw Hide (albeit fixed differently)


Note You need to log in before you can comment on or make changes to this bug.