]> git.kaiwu.me - njs.git/commitdiff
Style fixes and small miscellaneous changes.
authorIgor Sysoev <igor@sysoev.ru>
Tue, 4 Apr 2017 10:23:10 +0000 (13:23 +0300)
committerIgor Sysoev <igor@sysoev.ru>
Tue, 4 Apr 2017 10:23:10 +0000 (13:23 +0300)
njs/njs_array.c
njs/njs_function.c
njs/njs_parser.c

index 3f02e2bb9ab8b0963772e5319acbb3d9b9a0aeec..9cc980fd373007d505a400d17be465a696278d09 100644 (file)
@@ -2044,7 +2044,7 @@ njs_array_prototype_sort_continuation(njs_vm_t *vm, njs_value_t *args,
             sort->current++;
             n = sort->current;
 
-        } while (sort->current < array->length);
+        } while (n < array->length);
     }
 
     vm->retval = args[0];
index df620d853fb464f32677cf6001303bdcf90755da..56a99ca8445471cd0bc46e7fe1d1c0592c044cd2 100644 (file)
@@ -162,7 +162,7 @@ njs_function_frame(njs_vm_t *vm, njs_function_t *function,
     nxt_bool_t ctor)
 {
     size_t                 size;
-    nxt_uint_t             n, max_args, closures;;
+    nxt_uint_t             n, max_args, closures;
     njs_value_t            *value, *bound;
     njs_frame_t            *frame;
     njs_native_frame_t     *native_frame;
@@ -594,7 +594,7 @@ njs_function_activate(njs_vm_t *vm, njs_function_t *function, njs_value_t *this,
         cont->retval = retval;
 
         cont->return_address = vm->current
-                               + sizeof(njs_vmcode_function_call_t);;
+                               + sizeof(njs_vmcode_function_call_t);
         vm->current = (u_char *) njs_continuation_nexus;
 
         return NJS_APPLIED;
index 7fee2a46dffa0e2ba1fb2a0e9261f080ce4d22ec..461fd63f8fde12adfe7b89dc07bc6b15e8579424 100644 (file)
@@ -178,7 +178,7 @@ njs_parser_scope_begin(njs_vm_t *vm, njs_parser_t *parser, njs_scope_t type)
     if (type == NJS_SCOPE_FUNCTION) {
         scope->next_index[0] = type;
         scope->next_index[1] = NJS_SCOPE_CLOSURE + nesting
-                               + sizeof(njs_value_t);;
+                               + sizeof(njs_value_t);
 
     } else {
         if (type == NJS_SCOPE_GLOBAL) {