--- libaitcli/src/aitcli.c 2010/12/07 15:09:02 1.2.2.18 +++ libaitcli/src/aitcli.c 2010/12/07 15:15:34 1.2.2.19 @@ -3,7 +3,7 @@ * by Michael Pounov * * $Author: misho $ -* $Id: aitcli.c,v 1.2.2.18 2010/12/07 15:09:02 misho Exp $ +* $Id: aitcli.c,v 1.2.2.19 2010/12/07 15:15:34 misho Exp $ * *************************************************************************/ #include "global.h" @@ -1270,7 +1270,6 @@ cliNetLoop(linebuffer_t * __restrict buffer, const cha } else close(sock); - cliInitLine(buffer); ret = cliLoop(buffer, csHistFile) < 0 ? 1 : 0; cliEnd(buffer); @@ -1378,6 +1377,7 @@ cliLoop(linebuffer_t * __restrict buffer, const char * struct tagCommand *cmd; /* --- main body of CLI --- */ + cliInitLine(buffer); if (cli_loadHistory(buffer, csHistFile) == RETCODE_ERR) return RETCODE_ERR;