From be92057fa7881188643081bd3c3dbb78a59508a5 Mon Sep 17 00:00:00 2001 From: Con Kolivas Date: Sat, 14 Jun 2014 17:04:18 +1000 Subject: [PATCH] Write the errno to the share json --- src/stratifier.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/stratifier.c b/src/stratifier.c index 1fb150c1..0fcb337c 100644 --- a/src/stratifier.c +++ b/src/stratifier.c @@ -1685,6 +1685,7 @@ out_unlock: json_set_bool(val, "result", result); json_object_set(val, "reject-reason", json_object_dup(json_msg, "reject-reason")); json_object_set(val, "error", *err_val); + json_set_int(val, "errno", err); json_set_string(val, "createdate", cdfield); json_set_string(val, "createby", "code"); json_set_string(val, "createcode", __func__); @@ -1717,12 +1718,13 @@ out_unlock: json_decref(val); out: if (!share) { - val = json_pack("{ss,si,ss,ss,so,ss,ss,ss,ss}", + val = json_pack("{ss,si,ss,ss,so,si,ss,ss,ss,ss}", "method", "shareerror", "workinfoid", current_workbase->id, "worker", client->workername, "username", client->user_instance->username, "error", json_copy(*err_val), + "errno", err, "createdate", cdfield, "createby", "code", "createcode", __func__,