projects
/
apps
/
madmutt.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
wibble
[apps/madmutt.git]
/
lib-ui
/
query.c
diff --git
a/lib-ui/query.c
b/lib-ui/query.c
index
2a60afa
..
62ecd9a
100644
(file)
--- a/
lib-ui/query.c
+++ b/
lib-ui/query.c
@@
-7,21
+7,12
@@
* please see the file GPL in the top level source directory.
*/
* please see the file GPL in the top level source directory.
*/
-#if HAVE_CONFIG_H
-# include "config.h"
-#endif
+#include <lib-lib/lib-lib.h>
-#include <string.h>
-#include <stdlib.h>
-#include <ctype.h>
-
-#include <lib-lib/mem.h>
-#include <lib-lib/str.h>
-#include <lib-lib/macros.h>
-#include <lib-lib/file.h>
-#include <lib-lib/mapping.h>
+#include <lib-sys/unix.h>
#include <lib-ui/menu.h>
#include <lib-ui/menu.h>
+#include <lib-ui/curses.h>
#include "mutt.h"
#include "alias.h"
#include "mutt.h"
#include "alias.h"
@@
-128,7
+119,7
@@
static QUERY *run_query (char *s, int quiet)
}
}
p_delete(&buf);
}
}
p_delete(&buf);
-
fclose (
fp);
+
m_fclose(&
fp);
if (mutt_wait_filter (thepid)) {
if (!quiet)
mutt_error ("%s", msg);
if (mutt_wait_filter (thepid)) {
if (!quiet)
mutt_error ("%s", msg);
@@
-350,7
+341,7
@@
static void query_menu (char *buf, ssize_t buflen, QUERY * results, int retbuf)
QueryTable[i].data = queryp;
}
else {
QueryTable[i].data = queryp;
}
else {
- int clear = 0;
+ int
do
clear = 0;
/* append */
p_realloc(&QueryTable, menu->max);
/* append */
p_realloc(&QueryTable, menu->max);
@@
-361,10
+352,10
@@
static void query_menu (char *buf, ssize_t buflen, QUERY * results, int retbuf)
queryp = queryp->next, i++) {
/* once we hit new entries, clear/init the tag */
if (queryp == newresults)
queryp = queryp->next, i++) {
/* once we hit new entries, clear/init the tag */
if (queryp == newresults)
- clear = 1;
+
do
clear = 1;
QueryTable[i].data = queryp;
QueryTable[i].data = queryp;
- if (clear)
+ if (
do
clear)
QueryTable[i].tagged = 0;
}
}
QueryTable[i].tagged = 0;
}
}