Date: Sun, 18 Apr 2004 12:45:46 -0400 (EDT) From: Daniel Eischen <eischen@vigrid.com> To: "Conrad J. Sabatier" <conrads@cox.net> Cc: freebsd-ports@freebsd.org Subject: Re: xmcd now requires ATAPICAM for IDE CD-ROM? Message-ID: <Pine.GSO.4.10.10404181241300.22976-100000@pcnet5.pcnet.com> In-Reply-To: <20040418094524.GA21479@cox.net>
next in thread | previous in thread | raw e-mail | index | archive | help
On Sun, 18 Apr 2004, Conrad J. Sabatier wrote: > The latest version of xmcd segfaults when I try to run cda (under > FreeBSD 5.2-CURRENT), just after reading (or attempting to read) > /etc/nsswitch.conf, it looks like. > > I'm not using ATAPICAM in my kernel, but browsing through the port, it looks > like there may be a dependency on CAM(?). > > Any ideas, anyone? It seems to segfault at cdinfo_d/cdinfo_x.c at line 3177: if (newmenu) { -> if (cdinfo_dbp->wwwwarp_list == NULL) cdinfo_dbp->wwwwarp_list = wp1 = wp; else { wp1->nextmenu = wp; wp1 = wp; } } with a null pointer dereference. I poked around a little and cdinfo_dbp is setup by calling cdinfo_init() which seems to be done after cdinfo_wwwwarp_parmload() is called (where it segfaults). This patch seems to fix it for me, but the author should take a look at it. Perhaps we're doing something else wrong... -- Dan Eischen [ add the patch to ports/audio/xmcd/patch-ai ] --- cda_d/cda.c.orig Sun Apr 18 12:02:09 2004 +++ cda_d/cda.c Sun Apr 18 12:02:39 2004 @@ -7716,9 +7716,6 @@ (void) sprintf(path, USR_CMCFG_PATH, hd); di_common_parmload(path, FALSE, FALSE); - /* Set up basic wwwWarp structure */ - cdinfo_wwwwarp_parmload(); - if (app_data.device != NULL && (int) strlen(app_data.device) >= FILE_PATH_SZ) CDA_FATAL(app_data.str_longpatherr); @@ -7757,6 +7754,9 @@ cdinfo_cldata.fatal_msg = cda_fatal_msg; cdinfo_cldata.warning_msg = cda_warning_msg; cdinfo_init(&cdinfo_cldata); + + /* Set up basic wwwWarp structure */ + cdinfo_wwwwarp_parmload(); #ifndef NOVISUAL if (visual) {
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.GSO.4.10.10404181241300.22976-100000>