zsh-workers
 help / color / mirror / code / Atom feed
* Buglette & Fix for checkrmall in 4.0.2
@ 2001-10-15 11:32 Stefan Dalibor
  2001-10-15 16:53 ` Bart Schaefer
                   ` (2 more replies)
  0 siblings, 3 replies; 7+ messages in thread
From: Stefan Dalibor @ 2001-10-15 11:32 UTC (permalink / raw)
  To: zsh-workers

[-- Attachment #1: Type: text/plain, Size: 1224 bytes --]

Hi,
just in case nobody else has been stumbled into this: 4.0.2 segfaults
in checkrmall() (under OpenLinux 3.1, i.e. Linux 2.4.* with glibc 2.2.1
and 2.2.4) when executing the following function:

function www {
	typeset netscapefiles="{lock,plugin-list*,history*,*cache/*,archive/*,*.db,abook.nab,registry,summary*,custom.dic}" \
		nsmaildir=$HOME/nsmail
	(	
		if [ -z "$DISPLAY" -a "$KPSYSTYPE" = 'i86linux' ]; then
			# Fire up X and start Mozilla from Linux text console:
			startx netscape "$@"
		else
			netscape "$@"
		fi
		# This crashes zsh-4.0.2 if unpatched:
		eval command rm -fr $HOME/.netscape/$netscapefiles /tmp/ndebug
		[ -d $nsmaildir ] && rmdir $nsmaildir
	) &
}

This is due to checkrmall() calling fprintf() with a NULL file ptr in
shout.

Please find attached the dumbest possible patch... it prevents the crash,
but I didn't investigate on wether it is the appropriate place for a
fix (should Zsh recognize that it's useless to call checkrmall() when
running in the background in the first place?  Is the NULL file ptr a
bug in itself?).

Cheers,
Stefan

P.S.: If you have any further questions, please set me on CC (I'm only on
      the Zsh announce list)
--
Dr.Ing. Stefan Dalibor <scd@caldera.de>

[-- Attachment #2: zsh-4.0.2-nostderrfix.patch --]
[-- Type: application/x-patch, Size: 384 bytes --]

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2001-10-20 17:48 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-10-15 11:32 Buglette & Fix for checkrmall in 4.0.2 Stefan Dalibor
2001-10-15 16:53 ` Bart Schaefer
2001-10-15 17:07   ` Peter Stephenson
2001-10-15 18:13     ` Borsenkow Andrej
2001-10-15 19:30       ` Bart Schaefer
2001-10-15 17:03 ` Bart Schaefer
2001-10-20 17:48 ` Bart Schaefer

Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).