summaryrefslogtreecommitdiffstats
path: root/src/imap/cmd-check.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/imap/cmd-check.c')
-rw-r--r--src/imap/cmd-check.c14
1 files changed, 14 insertions, 0 deletions
diff --git a/src/imap/cmd-check.c b/src/imap/cmd-check.c
new file mode 100644
index 0000000..a456f7c
--- /dev/null
+++ b/src/imap/cmd-check.c
@@ -0,0 +1,14 @@
+/* Copyright (c) 2002-2018 Dovecot authors, see the included COPYING file */
+
+#include "imap-common.h"
+#include "imap-commands.h"
+
+bool cmd_check(struct client_command_context *cmd)
+{
+ if (!client_verify_open_mailbox(cmd))
+ return TRUE;
+
+ return cmd_sync(cmd, MAILBOX_SYNC_FLAG_FULL_READ |
+ MAILBOX_SYNC_FLAG_FULL_WRITE, IMAP_SYNC_FLAG_SAFE,
+ "OK Check completed.");
+}