This commit is contained in:
Max Lv
2017-01-23 08:39:11 +08:00
parent 71d5453f88
commit bcdc5559a8
2 changed files with 7 additions and 0 deletions
+4
View File
@@ -201,6 +201,10 @@ read_jconf(const char *file)
conf.user = to_string(value);
} else if (strcmp(name, "plugin") == 0) {
conf.plugin = to_string(value);
if (strlen(conf.plugin) == 0) {
ss_free(conf.plugin);
conf.plugin = NULL;
}
} else if (strcmp(name, "plugin_opts") == 0) {
conf.plugin_opts = to_string(value);
} else if (strcmp(name, "fast_open") == 0) {
+3
View File
@@ -94,6 +94,9 @@ start_plugin(const char *plugin,
if (plugin == NULL)
return -1;
if (strlen(plugin) == 0)
return 0;
size_t plugin_len = strlen(plugin);
size_t cmd_len = plugin_len + CMD_RESRV_LEN;
cmd = ss_malloc(cmd_len);