Skip to content

Commit

Permalink
#194: redefinition warnings, invalid type in doveadm-rbox command
Browse files Browse the repository at this point in the history
  • Loading branch information
jrse committed Oct 25, 2018
1 parent 3b6db40 commit 33a5f8e
Show file tree
Hide file tree
Showing 4 changed files with 28 additions and 6 deletions.
6 changes: 6 additions & 0 deletions src/librmb/tools/rmb/rmb.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,12 @@
#include "rados-dovecot-ceph-cfg-impl.h"
#include "rados-metadata-storage-default.h"
#include "rmb-commands.h"
#undef PACKAGE_BUGREPORT
#undef PACKAGE_NAME
#undef PACKAGE_STRING
#undef PACKAGE_TARNAME
#undef PACKAGE_URL
#undef PACKAGE_VERSION
#include "config-local.h"

static void argv_to_vec(int argc, const char **argv, std::vector<const char *> *args) {
Expand Down
7 changes: 7 additions & 0 deletions src/storage-rbox/debug-helper.h
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,13 @@
* License version 2.1, as published by the Free Software
* Foundation. See file COPYING.
*/

#undef PACKAGE_BUGREPORT
#undef PACKAGE_NAME
#undef PACKAGE_STRING
#undef PACKAGE_TARNAME
#undef PACKAGE_URL
#undef PACKAGE_VERSION
#include "config-local.h"
#ifndef SRC_STORAGE_RBOX_DEBUG_HELPER_H_
#define SRC_STORAGE_RBOX_DEBUG_HELPER_H_
Expand Down
11 changes: 10 additions & 1 deletion src/storage-rbox/doveadm-rbox-plugin.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -9,14 +9,15 @@
* License version 2.1, as published by the Free Software
* Foundation. See file COPYING.
*/

#include <algorithm>
#include <list>
#include <map>
#include <string>
#include <vector>

extern "C" {
#include "config-local.h"

#include "lib.h"
#include "module-dir.h"
#include "str.h"
Expand All @@ -36,6 +37,14 @@ extern "C" {
#include "doveadm-cmd.h"
#include "istream.h"
#include "doveadm-print.h"

#undef PACKAGE_BUGREPORT
#undef PACKAGE_NAME
#undef PACKAGE_STRING
#undef PACKAGE_TARNAME
#undef PACKAGE_URL
#undef PACKAGE_VERSION
#include "config-local.h"
}

#include "tools/rmb/rmb-commands.h"
Expand Down
10 changes: 5 additions & 5 deletions src/storage-rbox/doveadm-rbox.c
Original file line number Diff line number Diff line change
Expand Up @@ -36,11 +36,11 @@ static struct doveadm_mail_cmd rmb_commands[] = {
{cmd_rmb_check_indices_alloc, "rmb check indices", "-d"},
{cmd_rmb_mailbox_delete_alloc, "rmb mailbox delete", "-r <mailbox> [...]"}};

struct doveadm_cmd doveadm_cmd_rbox[] = {{cmd_rmb_config_show, "rmb config show", NULL},
{cmd_rmb_config_create, "rmb config create", NULL},
{cmd_rmb_config_update, "rmb config update", "key=value"},
{cmd_rmb_lspools, "rmb lspools", ""},
{cmd_rmb_version, "rmb version", ""}};
struct doveadm_cmd doveadm_cmd_rbox[] = {{(void *)cmd_rmb_config_show, "rmb config show", NULL},
{(void *)cmd_rmb_config_create, "rmb config create", NULL},
{(void *)cmd_rmb_config_update, "rmb config update", "key=value"},
{(void *)cmd_rmb_lspools, "rmb lspools", ""},
{(void *)cmd_rmb_version, "rmb version", ""}};

void doveadm_rbox_plugin_init(struct module *module ATTR_UNUSED) {
unsigned int i;
Expand Down

0 comments on commit 33a5f8e

Please sign in to comment.