zsh-workers
 help / color / mirror / code / Atom feed
* Re: Crash when invoking vared on a non-existent shell variable
       [not found] <B5885AA769039C49BD9295955CB2E0E40589799B@lonpexch501.ctxuk.citrix.com>
@ 2004-03-24 16:30 ` Peter Stephenson
  0 siblings, 0 replies; 3+ messages in thread
From: Peter Stephenson @ 2004-03-24 16:30 UTC (permalink / raw)
  To: John Cooper, Zsh hackers list

John Cooper wrote:
> When I invoke vared on a variable that doesn't exist, the shell crashes with
> the following:

Are you runing over a problem I sometimes have with cygwin that zwarnnam
doesn't get linked into modules properly and the shell crashes when a
module tries to call it?  If so, it's not just me and it should be
reported.  You should be able to see warnings about trying to import
zwarnnam as a data symbol.

It seems that the last symbol in the export list is not scanned properly
by dlltool.  My simple-minded workaround is to add another one even later.
(Remake until the warnings go away.  I'm not sure if the dependencies
are quite up to this.)

Index: Src/utils.c
===================================================================
RCS file: /cvsroot/zsh/zsh/Src/utils.c,v
retrieving revision 1.57
diff -u -r1.57 utils.c
--- Src/utils.c	17 Dec 2003 20:47:39 -0000	1.57
+++ Src/utils.c	24 Mar 2004 16:16:29 -0000
@@ -110,6 +110,13 @@
     zerrmsg(fmt, str, num);
 }
 
+#ifdef __CYGWIN__
+mod_export void
+zz_plural_z_alpha(void)
+{
+}
+#endif
+
 /**/
 void
 zerrmsg(const char *fmt, const char *str, int num)

-- 
Peter Stephenson <pws@csr.com>                  Software Engineer
CSR Ltd., Science Park, Milton Road,
Cambridge, CB4 0WH, UK                          Tel: +44 (0)1223 692070


**********************************************************************
This email and any files transmitted with it are confidential and
intended solely for the use of the individual or entity to whom they
are addressed. If you have received this email in error please notify
the system manager.

This footnote also confirms that this email message has been swept by
MIMEsweeper for the presence of computer viruses.

www.mimesweeper.com
**********************************************************************


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

* Re: Crash when invoking vared on a non-existent shell variable
       [not found] <B5885AA769039C49BD9295955CB2E0E4058979A1@lonpexch501.ctxuk.citrix.com>
@ 2004-03-25 12:52 ` Peter Stephenson
  0 siblings, 0 replies; 3+ messages in thread
From: Peter Stephenson @ 2004-03-25 12:52 UTC (permalink / raw)
  To: John Cooper, Zsh hackers list

John Cooper wrote:
> OK, I misunderstood.  When I recompiled I did get warnings about zwarnnam
> (see attached logs before and after the patch) and your patch does seem to
> have fixed the problem.  I only needed to rebuild once to get rid of the
> warnings.
> 
> Should the patch be incorporated into the source? 

I've committed it, since it's harmless, but someone needs to
characterise this and tell Cygwin.  I couldn't see any reports on the
cygwin mailing list.  I'll send an initial mail.

-- 
Peter Stephenson <pws@csr.com>                  Software Engineer
CSR Ltd., Science Park, Milton Road,
Cambridge, CB4 0WH, UK                          Tel: +44 (0)1223 692070


**********************************************************************
The information transmitted is intended only for the person or
entity to which it is addressed and may contain confidential 
and/or privileged material. 
Any review, retransmission, dissemination or other use of, or
taking of any action in reliance upon, this information by 
persons or entities other than the intended recipient is 
prohibited. 
If you received this in error, please contact the sender and 
delete the material from any computer.
**********************************************************************


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

* Re: Crash when invoking vared on a non-existent shell variable
       [not found] <B5885AA769039C49BD9295955CB2E0E40589799E@lonpexch501.ctxuk.citrix.com>
@ 2004-03-25 10:10 ` Peter Stephenson
  0 siblings, 0 replies; 3+ messages in thread
From: Peter Stephenson @ 2004-03-25 10:10 UTC (permalink / raw)
  To: John Cooper, Zsh hackers list

John Cooper wrote:
> Hm.  I haven't noticed any warnings about zwarnnam, although I've only been
> using cygwin zsh for a few days now (since 4.2.0 was released). I'll keep a
> look out for it...

You only get the warning on compilation.  If it didn't get linked
properly, then any attempt to use it causes the crash as you saw.  It's
surprisingly hard to notice since a lot of modules (especially the zle
ones) don't issue warnings.  The vared one is probably the most obvious.

-- 
Peter Stephenson <pws@csr.com>                  Software Engineer
CSR Ltd., Science Park, Milton Road,
Cambridge, CB4 0WH, UK                          Tel: +44 (0)1223 692070


**********************************************************************
This email and any files transmitted with it are confidential and
intended solely for the use of the individual or entity to whom they
are addressed. If you have received this email in error please notify
the system manager.

This footnote also confirms that this email message has been swept by
MIMEsweeper for the presence of computer viruses.

www.mimesweeper.com
**********************************************************************


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

end of thread, other threads:[~2004-03-25 12:53 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <B5885AA769039C49BD9295955CB2E0E40589799B@lonpexch501.ctxuk.citrix.com>
2004-03-24 16:30 ` Crash when invoking vared on a non-existent shell variable Peter Stephenson
     [not found] <B5885AA769039C49BD9295955CB2E0E40589799E@lonpexch501.ctxuk.citrix.com>
2004-03-25 10:10 ` Peter Stephenson
     [not found] <B5885AA769039C49BD9295955CB2E0E4058979A1@lonpexch501.ctxuk.citrix.com>
2004-03-25 12:52 ` Peter Stephenson

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