Index: /trunk/FACT++/src/Readline.cc
===================================================================
--- /trunk/FACT++/src/Readline.cc	(revision 11130)
+++ /trunk/FACT++/src/Readline.cc	(revision 11131)
@@ -949,6 +949,4 @@
 bool Readline::Process(const string &str)
 {
-    fCommandLog << str << endl;
-
     if (str.substr(0, 3)==".w ")
     {
@@ -1055,4 +1053,24 @@
 
     return str;
+}
+
+// --------------------------------------------------------------------------
+//
+//! Process a single line. All lines are added to the history, but only
+//! accepted lines are written to the command log. Inthis case fLine is
+//! increased by one.
+//
+void Readline::ProcessLine(const string &str)
+{
+    const bool rc = Process(str);
+
+    AddToHistory(str);
+
+    if (rc)
+        return;
+
+    fLine++;
+
+    fCommandLog << str << endl;
 }
 
@@ -1094,10 +1112,5 @@
             abort();
 
-        if (Process(str))
-            continue;
-
-        fLine++;
-
-        AddToHistory(str);
+        ProcessLine(str);
     }
 }
@@ -1145,10 +1158,5 @@
         }
 
-        if (Process(buffer))
-            continue;
-
-        fLine++;
-
-        AddToHistory(buffer);
+        ProcessLine(buffer);
     }
 
Index: /trunk/FACT++/src/Readline.h
===================================================================
--- /trunk/FACT++/src/Readline.h	(revision 11130)
+++ /trunk/FACT++/src/Readline.h	(revision 11131)
@@ -54,4 +54,7 @@
     void SetCompletion(const std::vector<std::string> *v) { fCompletion = v; }
     char **Complete(const std::vector<std::string> &v, const char *text);
+
+    // Wrapper for some process code
+    void ProcessLine(const std::string &str);
 
 public:
