Commit 8e127f21 8e127f21bf8b5036a1a08437de6959b6d4b41a27 by Sean 'Shaleh' Perry

mh code flesh out

1 parent eda27cd4
2000-01-19 Sean 'Shaleh' Perry
* mailbox/mbx_mh.c: some more code fleshing, still ugly
2000-01-19 Sean 'Shaleh' Perry
* mailbox/mbx_mh.c: new file
no header, no error checking, no hable englais
* url/url_mh.{c,h}: new files
......
......@@ -109,6 +109,7 @@ mh_scan (mailbox_t mbox, size_t *msgs)
struct dirent *entry;
mh_data *data;
unsigned int count = 0;
int parse_sequence_file = 0;
data = mbox->data;
......@@ -129,6 +130,7 @@ mh_scan (mailbox_t mbox, size_t *msgs)
continue; /* spurious file beginning w/ '.' */
else { /* MH info in .mh_sequences */
/* FIXME: parse this file */
parse_sequence_file = 1;
}
}
if(mh_sequence(entry->d_name)) {
......@@ -138,6 +140,17 @@ mh_scan (mailbox_t mbox, size_t *msgs)
}
closedir(maildir);
if(parse_sequence_file && count) {
char *path = malloc(strlen(mbox->name) + strlen(".mh_sequences") + 2);
sprintf(path, "%s/.mh_sequences", mbox->name);
fp = fopen(path, "r");
while(!feof(fp)) {
/* FIXME: parse the contents */
}
fclose(fp);
free(path);
}
stat(mbox->name, &st);
data->mtime = st.st_mtime;
......