maildir-build.c revision db1ee4a91a6572602302115e02146b29adea3a54
/* Copyright (C) 2002 Timo Sirainen */
#include "lib.h"
#include "istream.h"
#include "maildir-index.h"
#include "mail-index-util.h"
#include <unistd.h>
#include <fcntl.h>
{
enum mail_data_field cache_fields;
if (index->mail_read_mmaped) {
MAIL_MMAP_BLOCK_SIZE, 0, 0, FALSE);
} else {
}
return TRUE;
}
{
struct mail_index_record *rec;
struct mail_index_update *update;
const char *p;
int failed;
return FALSE;
return FALSE;
/* set message flags from file name */
/* set virtual size if found from file name */
if (p != NULL) {
p += 3;
virtual_size = 0;
while (*p >= '0' && *p <= '9') {
p++;
}
if (*p == ':' || *p == ',' || *p == '\0') {
sizeof(virtual_size));
}
}
/* set internal date */
}
/* set the location */
if (new_dir)
/* parse the header and update record's fields */
return FALSE;
}
}
{
const char *path;
/* nothing cached, don't bother opening the file */
}
if (fd == -1) {
/* it's not found because it's deleted or renamed.
don't try to handle any error cases here, just
save the thing and let the syncing handle it
later */
}
}
return ret;
}