From: Timo Sirainen Date: Fri, 2 Oct 2015 09:10:41 +0000 (+0300) Subject: push-notification: Allow drivers to set only "key" without "=value" to parameters. X-Git-Tag: 2.2.19~4 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=fe1fb4c867cd78b1d20fa59f8e656fef257ec00b;p=thirdparty%2Fdovecot%2Fcore.git push-notification: Allow drivers to set only "key" without "=value" to parameters. --- diff --git a/src/plugins/push-notification/push-notification-drivers.c b/src/plugins/push-notification/push-notification-drivers.c index b28125f686..d1153cef81 100644 --- a/src/plugins/push-notification/push-notification-drivers.c +++ b/src/plugins/push-notification/push-notification-drivers.c @@ -66,9 +66,12 @@ push_notification_driver_parse_config(const char *p) p2 = strchr(*args, '='); if (p2 != NULL) { key = t_strdup_until(*args, p2); - value = t_strdup(p2 + 1); - hash_table_insert(config->config, key, value); - } + value = t_strdup(p2 + 1); + } else { + key = *args; + value = ""; + } + hash_table_insert(config->config, key, value); } return config;