]> git.pld-linux.org Git - packages/poldek.git/blob - poldek-cli-hist.patch
- apply multilib patch only for x86-64.
[packages/poldek.git] / poldek-cli-hist.patch
1 ===================================================================
2 RCS file: /cvsroot/poldek/poldek/cli/shell.c,v
3 retrieving revision 1.28
4 retrieving revision 1.29
5 diff -u -r1.28 -r1.29
6 --- poldek/poldek/cli/shell.c   2006/01/07 01:06:48     1.28
7 +++ poldek/poldek/cli/shell.c   2006/05/11 09:51:53     1.29
8 @@ -356,22 +356,34 @@
9          snprintf(prompt, sizeof(prompt), "poldek:%s%s> ",
10                   currdir == NULL ? "/" : *currdir->name == '/' ? "" : "/",
11                   currdir == NULL ? "" : currdir->name);
12 +
13          if ((line = readline(prompt)) == NULL)
14              break;
15  
16 +        /* add to history? */
17 +        s = line;
18 +        while (isspace(*s))
19 +            s++;
20 +        
21 +        if (*s)
22 +            add_history(line);
23 +                
24          s = n_str_strip_ws(line);
25          if (*s) {
26              int _verbose = poldek_verbose();
27 -            add_history(s);
28 -            //print_mem_info("BEFORE");
29 +            
30              shInCmd = 1;
31              DBGF("(%s)\n", s);
32 +
33 +            MEMINF("BEFORE %s\n", s);
34              poclidek_execline(cctx, NULL, s);
35 +            MEMINF("AFTER  %s\n", s);
36 +            
37              sigint_reset();
38              shDone = 0;
39              shInCmd = 0;
40 +
41              poldek_set_verbose(_verbose);
42 -            //print_mem_info("AFTER ");
43          }
44          free(line);
45          
This page took 0.103195 seconds and 3 git commands to generate.