[njs] Making njs_exception_error_create() thread-safe.

Dmitry Volyntsev xeioex at nginx.com
Thu Mar 15 12:15:47 UTC 2018


details:   http://hg.nginx.org/njs/rev/7bf6d9ba52b9
branches:  
changeset: 461:7bf6d9ba52b9
user:      Dmitry Volyntsev <xeioex at nginx.com>
date:      Thu Mar 15 15:15:24 2018 +0300
description:
Making njs_exception_error_create() thread-safe.

diffstat:

 njs/njs_error.c |  3 +--
 1 files changed, 1 insertions(+), 2 deletions(-)

diffs (13 lines):

diff -r 720520457bfd -r 7bf6d9ba52b9 njs/njs_error.c
--- a/njs/njs_error.c	Thu Mar 15 15:15:24 2018 +0300
+++ b/njs/njs_error.c	Thu Mar 15 15:15:24 2018 +0300
@@ -39,8 +39,7 @@ njs_exception_error_create(njs_vm_t *vm,
     nxt_int_t     ret;
     njs_value_t   string;
     njs_object_t  *error;
-
-    static char  buf[256];
+    char          buf[256];
 
     if (fmt != NULL) {
         va_start(args, fmt);


More information about the nginx-devel mailing list