Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/zabbix/zabbix.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVladislavs Sokurenko <vladislavs.sokurenko@zabbix.com>2021-01-29 17:26:44 +0300
committerVladislavs Sokurenko <vladislavs.sokurenko@zabbix.com>2021-02-01 11:17:52 +0300
commitb069be9aee624516e308e1800fac977ac92c34f0 (patch)
treeb3242562021534cff77273bc257277ce98a6408d /src/libs/zbxembed
parent91a060d22725419efd33a7086c7a67b9c101dd61 (diff)
.......PS. [ZBXNEXT-6386] raised javascript heap limit from 10 megabytes to 64 megabytes; fixed memory leak when heap limit is reached
.......PS. [ZBXNEXT-6386] raised javascript heap limit from 10 megabytes to 64 megabytes; fixed memory leak when heap limit is reached * commit 'ffaa7b7a876056d0062206f26e9ba17f12e38066': .D........ [ZBXNEXT-6386] updated ChangeLog to mention fixed memory leak .......PS. [ZBXNEXT-6386] fixed memory leak when heap limit is reached .D........ [ZBXNEXT-6386] added ChangeLog .......PS. [ZBXNEXT-6386] raised javascript heap limit from 10 megabytes to 64 megabytes (cherry picked from commit c129cad4cd6aec7486b2df6d1f2143ccd69ac281) (cherry picked from commit 79cc6641934575f7ac64e93a0b2d9f1376255ec1)
Diffstat (limited to 'src/libs/zbxembed')
-rw-r--r--src/libs/zbxembed/embed.c2
-rw-r--r--src/libs/zbxembed/httprequest.c4
2 files changed, 3 insertions, 3 deletions
diff --git a/src/libs/zbxembed/embed.c b/src/libs/zbxembed/embed.c
index a03256fd086..4d2b103a73a 100644
--- a/src/libs/zbxembed/embed.c
+++ b/src/libs/zbxembed/embed.c
@@ -27,7 +27,7 @@
#include "xml.h"
#include "embed.h"
-#define ZBX_ES_MEMORY_LIMIT (1024 * 1024 * 10)
+#define ZBX_ES_MEMORY_LIMIT (1024 * 1024 * 64)
#define ZBX_ES_TIMEOUT 10
#define ZBX_ES_STACK_LIMIT 1000
diff --git a/src/libs/zbxembed/httprequest.c b/src/libs/zbxembed/httprequest.c
index 2f8dfe12bbb..8ad63a2750a 100644
--- a/src/libs/zbxembed/httprequest.c
+++ b/src/libs/zbxembed/httprequest.c
@@ -330,8 +330,6 @@ static duk_ret_t es_httprequest_query(duk_context *ctx, const char *http_request
curl_easy_strerror(err));
goto out;
}
-
- duk_push_string(ctx, request->data);
out:
zbx_free(url);
zbx_free(contents);
@@ -339,6 +337,8 @@ out:
if (-1 != err_index)
return duk_throw(ctx);
+ duk_push_string(ctx, request->data);
+
return 1;
}