From de58242f94d003c093573120e2389a60adf4374c Mon Sep 17 00:00:00 2001 From: =?utf8?q?Jos=C3=A9=20Bollo?= Date: Wed, 24 May 2017 16:57:49 +0200 Subject: [PATCH] fix concurrency for afb_msg_json_reply_error MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Change-Id: I37ab68217c733456810e7e9ceb4e2e6c058f1b5b Signed-off-by: José Bollo --- src/afb-msg-json.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/src/afb-msg-json.c b/src/afb-msg-json.c index 6d8f7327..f2922cb8 100644 --- a/src/afb-msg-json.c +++ b/src/afb-msg-json.c @@ -107,12 +107,7 @@ struct afb_arg afb_msg_json_get_arg(struct json_object *object, const char *name struct json_object *afb_msg_json_internal_error() { - static struct json_object *obj; - - if (obj == NULL) - obj = afb_msg_json_reply_error("failed", "internal error", NULL, NULL); - - return obj; + return afb_msg_json_reply_error("failed", "internal error", NULL, NULL); } -- 2.16.6