zsh-workers
 help / color / mirror / code / Atom feed
* special parameter fix
@ 1997-04-01  0:06 Zefram
  0 siblings, 0 replies; only message in thread
From: Zefram @ 1997-04-01  0:06 UTC (permalink / raw)
  To: zsh-workers

-----BEGIN PGP SIGNED MESSAGE-----

My patch 3048 contained a small bug, in that its method of checking for
an attempt to change the type of a special parameter is ineffective.
The commands

typeset -R UID
echo $UID

will cause a crash without this patch.

 -zefram

 *** Src/builtin.c	1997/03/30 00:49:13	1.74
 --- Src/builtin.c	1997/03/31 04:01:22
 ***************
 *** 1415,1421 ****
   		continue;
   	    }
   	    if((pm->flags & PM_SPECIAL) &&
 ! 	       PM_TYPE(on) && PM_TYPE(on) != PM_TYPE(pm->flags)) {
   		zerrnam(name, "%s: cannot change type of a special parameter",
   		    pm->nam, 0);
   		returnval = 1;
 --- 1415,1421 ----
   		continue;
   	    }
   	    if((pm->flags & PM_SPECIAL) &&
 ! 	       PM_TYPE((pm->flags | on) & ~off) != PM_TYPE(pm->flags)) {
   		zerrnam(name, "%s: cannot change type of a special parameter",
   		    pm->nam, 0);
   		returnval = 1;

-----BEGIN PGP SIGNATURE-----
Version: 2.6.3ia
Charset: ascii

iQCVAwUBMz85T3D/+HJTpU/hAQHHdgP9G+Nbu1x6Ri0EH4ARUYfSr/FqNiKicnbp
HouaWVf1ken7j8ziTEve3Sc7aBLu754rPjm8THCZpJRNCrKAAhBPs/W/QCKqmFLI
Y+qlEGGq3XS0nTZCA1smLNmhTrQJpEPEsAm8zHY6McghQHn/V5cFC7LNP/Tb+X/x
OWytJ7IscO4=
=OcAb
-----END PGP SIGNATURE-----


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~1997-04-01  0:10 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1997-04-01  0:06 special parameter fix Zefram

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).