X-Git-Url: http://git.marmaro.de/?a=blobdiff_plain;f=uip%2Fnew.c;h=976337664d2909e3de4a9209130924f35a843cde;hb=refs%2Fheads%2Fmaster;hp=4335892e0497b636421449498e882f67ddc741bf;hpb=04a3dfc70394a517a79340a7d3ecd9c6a23d0bee;p=mmh diff --git a/uip/new.c b/uip/new.c index 4335892..21435b3 100644 --- a/uip/new.c +++ b/uip/new.c @@ -33,6 +33,8 @@ static struct swit switches[] = { { NULL, 0 } }; +char *version=VERSION; + static enum { NEW, FNEXT, FPREV, UNSEEN } run_mode = NEW; /* @@ -108,6 +110,10 @@ get_msgnums(char *folder, char *sequences[]) for (state = FLD2;;) { switch (state = m_getfld2(state, &f, fp)) { + case LENERR2: + state = FLD2; + /* FALL */ + case FLD2: /* ** if it's in a sequence we want, @@ -115,7 +121,10 @@ get_msgnums(char *folder, char *sequences[]) */ if (seq_in_list(f.name, sequences)) { this_msgnums = trimcpy(f.value); - if (msgnums == NULL) { + if (strlen(this_msgnums) == 0) { + free(this_msgnums); + continue; + } else if (msgnums == NULL) { msgnums = this_msgnums; } else { old_msgnums = msgnums;