Bug 8525 - Patch to fix a core dump in linuxconf
Patch to fix a core dump in linuxconf
Product: Red Hat Linux
Classification: Retired
Component: linuxconf (Show other bugs)
i386 Linux
medium Severity medium
: ---
: ---
Assigned To: Nalin Dahyabhai
Depends On:
  Show dependency treegraph
Reported: 2000-01-17 04:22 EST by Edward J. Huff
Modified: 2008-05-01 11:37 EDT (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2000-01-17 15:32:52 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Edward J. Huff 2000-01-17 04:22:42 EST
Enclosed find patches to fix a core dump in linuxconf, and how to
build an unstripped version so that emacs/gdb will bring up the source
code.  (You ought to have available a way of easily building an entire
system with no stripped code so any crash could be debugged easily
and all of the source code should be kept ready for access by gdb.
Disk space is cheap.)

I did an install everything, then installed all of the upgrades up to
Jan 1.  Somehow I lost the LINUXCONF.distribution redhat line from
/etc/conf.linuxconf.  (The RPM database was apparently corrupted,
claiming that linuxconf was both installed and not installed, or
something, so I reinstalled it with the --replacepkgs option.  The
privileges were wrong on /etc/conf.linuxconf.  Why didn't it show MD5
error?  I guess because configuration files are allowed to change...
I haven't tried to find out how this happened.  linuxconf ought to
display decent error dialogs so that you could easily figure out what
was wrong.  Or maybe rpm -V should notice if such vital lines in
the /etc/conf.linuxconf file are missing.

Missing LINUXCONF.distribution caused core dump in linuxconf.  The
core dump was caused by lack of init_dialog() call at top of linuxconf
main().  Adding that fixed the core dump.  (See patches below).

The error messages were still very unilluminating, since they refered
to path names containing "/DIST/" which is supposed to be substituted
by either /def/ or the LINUXCONF.distribution string from

They ought to either give the translated string or add "Where DIST is
the value of LINUXCONF.distribution in /etc/conf.linuxconf, or "def"".

[root@desk linuxconf-1.16r10]# pwd
[root@desk linuxconf-1.16r10]# find . -name '*~' -ls
145004   16 -rw-r--r--   1 root     root        13232 Jan 16 02:49
128950   12 -rw-r--r--   1 root     root         9647 Jan 16 02:49
[root@desk linuxconf-1.16r10]# diff main/main.cc main/main.cc~
< 	init_dialog();
[root@desk linuxconf-1.16r10]# diff Makefile Makefile~
< 	@echo "#omit strip $(BIN)/linuxconf"
< 	@echo "#omit -strip -S $(LIB_LINUXCONF)/modules/*.so.*"
> 	strip $(BIN)/linuxconf
> 	-strip -S $(LIB_LINUXCONF)/modules/*.so.*
[root@desk linuxconf-1.16r10]#

[root@desk bin]# pwd
[root@desk bin]# cd /usr/lib/linuxconf/
[root@desk linuxconf]# find . -name conf.daemons -ls
[root@desk linuxconf]# cd /usr/src/redhat/BUILD/linuxconf-1.16r10/
[root@desk linuxconf-1.16r10]# find . -name '*.[ch]*' -exec grep
conf.daemons {} \; -ls
128944    8 -rw-r--r--   1 root     root         7778 Jan 16 02:49
	The name of the command is used to located more info in /etc/conf.daemons.
 96495    8 -rw-r--r--   1 root     root         5012 Oct 23  1998
	Read a configuration file about command and path named (conf.daemons)
						mean that the conf.daemons files
	/* #Specification: conf.daemons / override
		The content of /usr/lib/linuxconf/conf.daemons can be overriden
 96513   12 -rw-r--r--   1 root     root         8415 Nov 27 23:41
128520    8 -rw-r--r--   1 root     root         7777 Nov 27 23:22

There is no such thing as /etc/conf.daemons (so comment is wrong)
Also no such thing as /usr/lib/DIST/, but it turns out that there is
code to change /DIST/ into /redhat/ based on the /etc/conf.linuxconf
LINUXCONF.distribution line.
Comment 1 Nalin Dahyabhai 2000-01-17 15:32:59 EST
Thanks for the patch.  It will be included in linuxconf-1.17r2-2, which will
be in the next release of Raw Hide.

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