From owner-freebsd-questions Tue Jul 2 8:27:39 2002 Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.FreeBSD.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 2AB1037B400 for ; Tue, 2 Jul 2002 08:27:37 -0700 (PDT) Received: from maul.immure.com (maul.immure.com [207.8.42.72]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4D62343E0A for ; Tue, 2 Jul 2002 08:27:36 -0700 (PDT) (envelope-from bob@immure.com) Received: (from root@localhost) by maul.immure.com (8.11.5/8.11.2) id g62FRZo66845 for freebsd-questions@freebsd.org; Tue, 2 Jul 2002 10:27:35 -0500 (CDT) (envelope-from bob@immure.com) Received: from luke.immure.com (luke.vieo.com [10.1.132.3]) by maul.immure.com (8.11.5/8.11.2) with ESMTP id g62FRZc66805 for ; Tue, 2 Jul 2002 10:27:35 -0500 (CDT) (envelope-from bob@immure.com) Received: (from root@localhost) by luke.immure.com (8.12.4/8.12.3) id g62FRZSN099480 for freebsd-questions@freebsd.org; Tue, 2 Jul 2002 10:27:35 -0500 (CDT) (envelope-from bob@luke.immure.com) Received: from luke.immure.com (localhost [127.0.0.1]) by luke.immure.com (8.12.4/8.12.3) with ESMTP id g62FRYZ7099451 for ; Tue, 2 Jul 2002 10:27:34 -0500 (CDT) (envelope-from bob@luke.immure.com) Received: (from bob@localhost) by luke.immure.com (8.12.4/8.12.4/Submit) id g62FRYB0099450 for freebsd-questions@freebsd.org; Tue, 2 Jul 2002 10:27:34 -0500 (CDT) Date: Tue, 2 Jul 2002 10:27:34 -0500 From: Bob Willcox To: questions list Subject: Re: awk getline question/odditiy -- nevermind :-) Message-ID: <20020702152734.GA99249@luke.immure.com> Reply-To: Bob Willcox References: <20020702060553.GA72170@luke.immure.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20020702060553.GA72170@luke.immure.com> User-Agent: Mutt/1.5.1i X-scanner: scanned by Inflex 1.0.12.3 on luke.immure.com X-scanner: scanned by Inflex 0.1.5c+ on maul.immure.com Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG I have discovered the answer. I had failed to "close" the command after the while loop. Adding a close function to my little example program like this fixes the problem: #!/usr/bin/awk -f { while ($0 | getline line > 0) print line close($0) } Thanks, Bob -- Bob Willcox Vital papers will demonstrate their vitality by bob@vieo.com spontaneously moving from where you left them to where Austin, TX you can't find them. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message