aboutsummaryrefslogtreecommitdiffstats
path: root/testing/dovecot-ceph-plugin/7-sentinel.patch
blob: e7edb24de5c6df6683e16b11749328964ebcbad4 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
submitted as:
https://github.com/ceph-dovecot/dovecot-ceph-plugin/pull/276

--- a/src/storage-rbox/rbox-mailbox-list-fs.cpp
+++ b/src/storage-rbox/rbox-mailbox-list-fs.cpp
@@ -101,7 +101,7 @@
   }
 
   /* we have at least one directory. see if this mailbox is selectable */
-  maildir_path = t_strconcat(path, "/", list->set.maildir_name, NULL);
+  maildir_path = t_strconcat(path, "/", list->set.maildir_name, static_cast<const char*>(NULL));
   if (stat(maildir_path, &st2) < 0)
     *flags_r |= MAILBOX_NOSELECT | MAILBOX_CHILDREN;
   else if (!S_ISDIR(st2.st_mode)) {
@@ -205,7 +205,7 @@
   }
 
   /* we've done all filtering we can before stat()ing */
-  path = t_strconcat(dir, "/", fname, NULL);
+  path = t_strconcat(dir, "/", fname, static_cast<const char*>(NULL));
   if (stat(path, &st) < 0) {
     if (ENOTFOUND(errno)) {
       *flags_r |= MAILBOX_NONEXISTENT;
--- a/src/storage-rbox/rbox-storage.cpp
+++ b/src/storage-rbox/rbox-storage.cpp
@@ -106,7 +106,7 @@
   const char *home;
 
   if (ns->owner != NULL && mail_user_get_home(ns->owner, &home) > 0) {
-    const char *path = t_strconcat(home, "/rbox", NULL);
+    const char *path = t_strconcat(home, "/rbox", static_cast<const char*>(NULL));
     if (access(path, R_OK | W_OK | X_OK) == 0) {
 #ifdef DEBUG
       i_debug("rbox: root exists (%s)", path);
@@ -142,7 +142,7 @@
     }
   }
 
-  path = t_strconcat(root_dir, "/" RBOX_MAILBOX_DIR_NAME, NULL);
+  path = t_strconcat(root_dir, "/" RBOX_MAILBOX_DIR_NAME, static_cast<const char*>(NULL));
   if (stat(path, &st) < 0) {
 #ifdef DEBUG
     i_debug("rbox autodetect: stat(%s) failed: %m", path);
@@ -343,7 +343,7 @@
     if (mailbox_get_path_to(box, MAILBOX_LIST_PATH_TYPE_INDEX, &box_path) < 0)
       return -1;
     i_assert(box_path != NULL);
-    box_path = t_strconcat(box_path, "/", box->index_prefix, ".log", NULL);
+    box_path = t_strconcat(box_path, "/", box->index_prefix, ".log", static_cast<const char*>(NULL));
     ret = stat(box_path, &st);
   }
 #endif
@@ -566,7 +566,7 @@
 
   const char *path;
   path = mailbox_list_get_root_forced(list, MAILBOX_LIST_PATH_TYPE_CONTROL);
-  path = t_strconcat(path, "/" RBOX_UIDVALIDITY_FILE_NAME, NULL);
+  path = t_strconcat(path, "/" RBOX_UIDVALIDITY_FILE_NAME, static_cast<const char*>(NULL));
 
   FUNC_END();
   return mailbox_uidvalidity_next(list, path);