This is the mail archive of the frysk@sources.redhat.com mailing list for the frysk project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

fix for fhpd buglet


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  <tromey@redhat.com>

	* 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);


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]