Mercurial > dovecot > original-hg > dovecot-1.2
view src/imap/cmd-create.c @ 91:dc0891523276 HEAD
bugfix for sync fix
author | Timo Sirainen <tss@iki.fi> |
---|---|
date | Thu, 29 Aug 2002 01:42:00 +0300 |
parents | 3b1985cbc908 |
children | 20769b7516a2 |
line wrap: on
line source
/* Copyright (C) 2002 Timo Sirainen */ #include "common.h" #include "commands.h" int cmd_create(Client *client) { const char *mailbox; /* <mailbox> */ if (!client_read_string_args(client, 1, &mailbox)) return FALSE; if (!client_verify_mailbox_name(client, mailbox, FALSE)) return TRUE; if (mailbox[strlen(mailbox)-1] == client->storage->hierarchy_sep) { /* name ends with hierarchy separator - client is just informing us that it wants to create a mailbox under this name. we don't need that information. */ } else if (!client->storage->create_mailbox(client->storage, mailbox)) { client_send_storage_error(client); return TRUE; } client_send_tagline(client, "OK Create completed."); return TRUE; }