NetBSD Problem Report #138
From gnats Wed Feb 23 12:49:15 1994
Received: from idefix.laas.fr (idefix.laas.fr [140.93.160.12]) by sun-lamp.cs.berkeley.edu (8.6.5/8.6.5) with SMTP id MAA11807 for <gnats-bugs@sun-lamp.cs.berkeley.edu>; Wed, 23 Feb 1994 12:49:13 -0800
Message-Id: <9402232049.AA04329@elwood.RIA>
Date: Wed, 23 Feb 1994 21:49:02 --100
From: matthieu@laas.fr (Matthieu Herrb)
To: gnats-bugs@sun-lamp.cs.berkeley.edu
Subject: awk "" dumps core
X-Send-Pr-Version: 3.2
>Number: 138
>Category: bin
>Synopsis: awk "" dumps core
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: gnats-admin
>State: closed
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Wed Feb 23 12:50:02 +0000 1994
>Closed-Date: Fri May 20 06:32:58 +0000 1994
>Last-Modified:
>Originator: Matthieu Herrb
>Release: 20/02 NetBSD-current
>Organization:
LAAS/CNRS
Toulouse France
>Environment:
gawk 2.15 patchlevel 4
System: NetBSD cougar 0.9a COUGAR#4 i386
>Description:
Calling awk with an empty string as 1st parameter causes an internal
error and a core dump.
Also submitted to Gnu awk mainteners.
>How-To-Repeat:
from C-shell:
awk ""
>Fix:
With this fix, awk produces a syntax error in the same conditions.
--- awk.y~ Thu Feb 17 11:11:06 1994
+++ awk.y Tue Feb 22 21:26:12 1994
@@ -854,7 +854,7 @@
errcount++;
/* Find the current line in the input file */
- if (lexptr) {
+ if (lexptr && lexeme) {
if (!thisline) {
cp = lexeme;
if (*cp == '\n') {
>Release-Note:
>Audit-Trail:
State-Changed-From-To: open->suspended
State-Changed-By: cgd
State-Changed-When: Wed Feb 23 17:20:26 PST 1994
State-Changed-Why:
see pr 123
State-Changed-From-To: suspended->closed
State-Changed-By: jtc
State-Changed-When: Fri May 20 06:32:58 1994
State-Changed-Why:
integrated gawk 2.15.5, which fixes this bug.
>Unformatted:
(Contact us)
$NetBSD: query-full-pr,v 1.51 2026/08/10 02:28:17 riastradh Exp $
$NetBSD: gnats_config.sh,v 1.10 2026/05/13 22:00:09 riastradh Exp $
Copyright © 1994-2026
The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.