Allow "q" to quit calculator, too. calculator-experiment
authorRyan C. Gordon <icculus@icculus.org>
Mon, 08 Feb 2010 03:33:12 -0500
branchcalculator-experiment
changeset 814 a2cf3f36ed1c
parent 813 a8ec84003cd2
child 815 c999c015cdc0
Allow "q" to quit calculator, too.
calculator.c
--- a/calculator.c	Mon Feb 08 03:30:48 2010 -0500
+++ b/calculator.c	Mon Feb 08 03:33:12 2010 -0500
@@ -414,6 +414,8 @@
     {
         if ((len == 5) && (memcmp(ln, "quit\n", 5) == 0))
             break;
+        else if ((len == 2) && (memcmp(ln, "q\n", 2) == 0))
+            break;
 
         MOJOSHADER_compile(filename, ln, (unsigned int) len,
                            NULL, 0, NULL, NULL, NULL, NULL, NULL);