From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 20681 invoked by alias); 16 May 2007 17:00:27 -0000 Received: (qmail 20672 invoked by uid 22791); 16 May 2007 17:00:27 -0000 X-Spam-Status: No, hits=-2.4 required=5.0 tests=AWL,BAYES_00,DK_POLICY_SIGNSOME,SPF_HELO_PASS,SPF_PASS,TW_FH X-Spam-Check-By: sourceware.org Received: from mx1.redhat.com (HELO mx1.redhat.com) (66.187.233.31) by sourceware.org (qpsmtpd/0.31) with ESMTP; Wed, 16 May 2007 17:00:24 +0000 Received: from int-mx1.corp.redhat.com (int-mx1.corp.redhat.com [172.16.52.254]) by mx1.redhat.com (8.13.1/8.13.1) with ESMTP id l4GH0MdB010746 for ; Wed, 16 May 2007 13:00:22 -0400 Received: from pobox.corp.redhat.com (pobox.corp.redhat.com [10.11.255.20]) by int-mx1.corp.redhat.com (8.13.1/8.13.1) with ESMTP id l4GH0MYx008497 for ; Wed, 16 May 2007 13:00:22 -0400 Received: from opsy.redhat.com (ton.toronto.redhat.com [172.16.14.15]) by pobox.corp.redhat.com (8.13.1/8.13.1) with ESMTP id l4GH0Kd4021694; Wed, 16 May 2007 13:00:20 -0400 Received: by opsy.redhat.com (Postfix, from userid 500) id 1F1563784D4; Wed, 16 May 2007 10:41:23 -0600 (MDT) To: Frysk List Subject: fix for fhpd buglet From: Tom Tromey Reply-To: tromey@redhat.com X-Attribution: Tom Date: Wed, 16 May 2007 17:18:00 -0000 Message-ID: User-Agent: Gnus/5.11 (Gnus v5.11) Emacs/22.0.95 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-IsSubscribed: yes Mailing-List: contact frysk-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Post: List-Help: , Sender: frysk-owner@sourceware.org X-SW-Source: 2007-q2/txt/msg00165.txt.bz2 I tried fhpd today and I noticed that if I typed Control-D at the prompt, it threw a null pointer exception. Patch appended. Tom Index: frysk-core/frysk/bindir/ChangeLog from Tom Tromey * fhpd.java (main): Exit loop if line==null. Index: frysk-core/frysk/bindir/fhpd.java =================================================================== RCS file: /cvs/frysk/frysk-core/frysk/bindir/fhpd.java,v retrieving revision 1.8 diff -u -r1.8 fhpd.java --- frysk-core/frysk/bindir/fhpd.java 3 May 2007 20:29:39 -0000 1.8 +++ frysk-core/frysk/bindir/fhpd.java 16 May 2007 16:56:15 -0000 @@ -125,7 +125,7 @@ reader.addCompletor(fhpdCompletor); try { cli.execCommand(line); - while (! (line.equals("quit") || line.equals("q"))) + while (line != null && ! (line.equals("quit") || line.equals("q"))) { line = reader.readLine(cli.getPrompt()); cli.execCommand(line);