#include <sys/types.h>
#include "h/mh.h"
+#include "sbr/m_getfld.h"
+#include "sbr/getarguments.h"
+#include "sbr/concat.h"
+#include "sbr/smatch.h"
+#include "sbr/r1bindex.h"
+#include "sbr/trimcpy.h"
+#include "sbr/vfgets.h"
#include "sbr/getcpy.h"
#include "sbr/m_atoi.h"
#include "sbr/context_save.h"
#include "sbr/print_version.h"
#include "sbr/print_help.h"
#include "sbr/error.h"
-#include "h/crawl_folders.h"
+#include "sbr/crawl_folders.h"
#include "h/done.h"
#include "h/utils.h"
#include "sbr/lock_file.h"
{
int total = 0;
int j, k;
- char *cp, **ap;
field = getcpy(field);
/* copied from seq_read.c:seq_init */
- for (ap = brkstring (field, " ", "\n"); *ap; ap++) {
- if ((cp = strchr(*ap, '-')))
+ for (char *const *ap = brkstring (field, " ", "\n"); *ap; ap++) {
+ char *cp = strchr(*ap, '-');
+ if (cp != NULL)
*cp++ = '\0';
if ((j = m_atoi (*ap)) > 0) {
k = cp ? m_atoi (cp) : j;
seqfile = concat(m_maildir(folder), "/", mh_seq, NULL);
if (seqfile == NULL)
- return NULL;
+ return NULL;
if ((fp = lkfopendata (seqfile, "r", & failed_to_lock)) == NULL) {
if (failed_to_lock)
int
main(int argc, char **argv)
{
- char **ap, *cp, **argp, **arguments;
+ char *cp, **argp, **arguments;
char help[BUFSIZ];
char *folders = NULL;
svector_t sequences = svector_create (0);
if (unseen == NULL || unseen[0] == '\0') {
die("must specify sequences or set %s", usequence);
}
- for (ap = brkstring(unseen, " ", "\n"); *ap; ap++) {
+ for (char *const *ap = brkstring(unseen, " ", "\n"); *ap; ap++) {
svector_push_back (sequences, *ap);
++i;
}