Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
* PATCH to expect: use proper version of TclRegComp
@ 2005-02-08 22:43 Jim Blandy
  2005-02-09  3:12 ` Andrew Cagney
  0 siblings, 1 reply; 3+ messages in thread
From: Jim Blandy @ 2005-02-08 22:43 UTC (permalink / raw)
  To: gdb-patches


I've committed the following to uberbaum's expect sources, as an
obvious fix.  Those sources don't seem to track the official Expect
sources any more, but the bug at hand doesn't exist in the official
sources anyway, so there's no need to push this upstream.

Without this patch, a build with --enable-shared breaks.  Non-shared
library builds work only because exp_clib.o in libexpect.a is never
needed to resolve any references in the executable, so it never gets
pulled in, so the unresolved reference it contains to TclRegComp never
gets noticed.  However, all the .o's get included in the shared
libexpect, so linking the expect executable against the .so does
produce an error.

2005-02-08  Jim Blandy  <jimb@redhat.com>

	* exp_clib.c (expectv): Use Expect_TclRegComp, not TclRegComp.
	This seems to have been missed in Ian Roxborough's 2001-07-09
	change.

Index: expect/exp_clib.c
===================================================================
RCS file: /cvs/src/src/expect/exp_clib.c,v
retrieving revision 1.3
diff -c -p -r1.3 exp_clib.c
*** expect/exp_clib.c	20 Nov 2002 00:28:58 -0000	1.3
--- expect/exp_clib.c	8 Feb 2005 21:15:30 -0000
*************** struct exp_case *ecases;
*** 773,779 ****
  	for (ec=ecases;ec->type != exp_end;ec++) {
  		if ((ec->type == exp_regexp) && !ec->re) {
  			TclRegError((char *)0);
! 			if (!(ec->re = (void*)TclRegComp(ec->pattern))) {
  				fprintf(stderr,"regular expression %s is bad: %s",ec->pattern,TclGetRegError());
  				return_errno(EINVAL);
  			  }
--- 773,779 ----
  	for (ec=ecases;ec->type != exp_end;ec++) {
  		if ((ec->type == exp_regexp) && !ec->re) {
  			TclRegError((char *)0);
! 			if (!(ec->re = (void*)Expect_TclRegComp(ec->pattern))) {
  				fprintf(stderr,"regular expression %s is bad: %s",ec->pattern,TclGetRegError());
  				return_errno(EINVAL);
  			  }


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

* Re: PATCH to expect: use proper version of TclRegComp
  2005-02-08 22:43 PATCH to expect: use proper version of TclRegComp Jim Blandy
@ 2005-02-09  3:12 ` Andrew Cagney
  2005-02-09 10:16   ` Jim Blandy
  0 siblings, 1 reply; 3+ messages in thread
From: Andrew Cagney @ 2005-02-09  3:12 UTC (permalink / raw)
  To: Jim Blandy; +Cc: gdb-patches, bje

FYI,

GDB no longer bundles src/expect/ or src/dejagnu/ so this list is no 
longer [one of] the place to send these sorts of patches.

enjoy,
Andrew


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

* Re: PATCH to expect: use proper version of TclRegComp
  2005-02-09  3:12 ` Andrew Cagney
@ 2005-02-09 10:16   ` Jim Blandy
  0 siblings, 0 replies; 3+ messages in thread
From: Jim Blandy @ 2005-02-09 10:16 UTC (permalink / raw)
  To: Andrew Cagney; +Cc: gdb-patches, bje


Andrew Cagney <cagney@gnu.org> writes:
> GDB no longer bundles src/expect/ or src/dejagnu/ so this list is no
> longer [one of] the place to send these sorts of patches.

Ahh, that's right.  And DejaGnu doesn't bundle expect either.  So I
guess the official expect is the only meaningful upstream source.

Tahnks.


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

end of thread, other threads:[~2005-02-09  3:12 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-02-08 22:43 PATCH to expect: use proper version of TclRegComp Jim Blandy
2005-02-09  3:12 ` Andrew Cagney
2005-02-09 10:16   ` Jim Blandy

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox