From owner-freebsd-bugs Mon Oct 29 7:40:11 2001 Delivered-To: freebsd-bugs@hub.freebsd.org Received: from freefall.freebsd.org (freefall.FreeBSD.org [216.136.204.21]) by hub.freebsd.org (Postfix) with ESMTP id 535C737B401 for ; Mon, 29 Oct 2001 07:40:03 -0800 (PST) Received: (from gnats@localhost) by freefall.freebsd.org (8.11.4/8.11.4) id f9TFe3G08820; Mon, 29 Oct 2001 07:40:03 -0800 (PST) (envelope-from gnats) Date: Mon, 29 Oct 2001 07:40:03 -0800 (PST) Message-Id: <200110291540.f9TFe3G08820@freefall.freebsd.org> To: freebsd-bugs@FreeBSD.org Cc: From: Maxim Konovalov Subject: Re: bin/31533: /bin/sh memory leak (fwd) Reply-To: Maxim Konovalov Sender: owner-freebsd-bugs@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org The following reply was made to PR bin/31533; it has been noted by GNATS. From: Maxim Konovalov To: freebsd-gnats-sumbit@freebsd.org Cc: Bob Bishop Subject: Re: bin/31533: /bin/sh memory leak (fwd) Date: Mon, 29 Oct 2001 16:32:32 +0300 (MSK) I resend the message because there is no my followup in gnats db. ---------- Forwarded message ---------- Date: Sat, 27 Oct 2001 20:11:25 +0400 (MSD) From: Maxim Konovalov To: Bob Bishop Cc: freebsd-bugs@FreeBSD.ORG Subject: Re: bin/31533: /bin/sh memory leak On Sat, 27 Oct 2001, Bob Bishop wrote: > The following reply was made to PR bin/31533; it has been noted by GNATS. > > From: Bob Bishop > To: freebsd-gnats-submit@FreeBSD.org, rb@gid.co.uk > Cc: > Subject: Re: bin/31533: /bin/sh memory leak > Date: Sat, 27 Oct 2001 16:39:58 +0100 > > Also affects -CURRENT How about this patch: Index: cd.c =================================================================== RCS file: /home/ncvs/src/bin/sh/cd.c,v retrieving revision 1.20 diff -u -r1.20 cd.c --- cd.c 29 Nov 1999 19:10:58 -0000 1.20 +++ cd.c 27 Oct 2001 16:07:20 -0000 @@ -238,8 +238,8 @@ curdir = NULL; if (getpwd() == NULL) error("getcwd() failed: %s", strerror(errno)); - setvar("PWD", curdir, VEXPORT | VTEXTFIXED); - setvar("OLDPWD", prevdir, VEXPORT | VTEXTFIXED); + setvar("PWD", curdir, VEXPORT); + setvar("OLDPWD", prevdir, VEXPORT); INTON; return; } @@ -270,8 +270,8 @@ ckfree(prevdir); prevdir = curdir; curdir = savestr(stackblock()); - setvar("PWD", curdir, VEXPORT | VTEXTFIXED); - setvar("OLDPWD", prevdir, VEXPORT | VTEXTFIXED); + setvar("PWD", curdir, VEXPORT); + setvar("OLDPWD", prevdir, VEXPORT); INTON; } -- Maxim Konovalov, MAcomnet, Internet-Intranet Dept., system engineer phone: +7 (095) 796-9079, mailto: maxim@macomnet.ru To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message