kill actor when abusive
This commit is contained in:
@@ -294,6 +294,12 @@ JS_IsShortFloat (JSValue v) {
|
||||
#define JS_FALSE ((JSValue)JS_TAG_BOOL)
|
||||
#define JS_TRUE ((JSValue)(JS_TAG_BOOL | (1 << 5)))
|
||||
#define JS_EXCEPTION ((JSValue)JS_TAG_EXCEPTION)
|
||||
#define JS_TAG_SUSPENDED 0x13 /* 10011 - distinct special tag */
|
||||
#define JS_SUSPENDED ((JSValue)JS_TAG_SUSPENDED)
|
||||
|
||||
static inline JS_BOOL JS_IsSuspended(JSValue v) {
|
||||
return JS_VALUE_GET_TAG(v) == JS_TAG_SUSPENDED;
|
||||
}
|
||||
|
||||
#ifndef JS_DEFAULT_STACK_SIZE
|
||||
#define JS_DEFAULT_STACK_SIZE (1024 * 1024)
|
||||
@@ -333,6 +339,12 @@ void JS_SetMaxStackSize (JSContext *ctx, size_t stack_size);
|
||||
used to check stack overflow. */
|
||||
void JS_UpdateStackTop (JSContext *ctx);
|
||||
|
||||
/* Returns the current VM call depth (0 = pure bytecode, >0 = C frames) */
|
||||
int JS_GetVMCallDepth(JSContext *ctx);
|
||||
|
||||
/* Set per-context heap memory limit (0 = no limit) */
|
||||
void JS_SetHeapMemoryLimit(JSContext *ctx, size_t limit);
|
||||
|
||||
/* return != 0 if the JS code needs to be interrupted */
|
||||
typedef int JSInterruptHandler (JSRuntime *rt, void *opaque);
|
||||
void JS_SetInterruptHandler (JSContext *ctx, JSInterruptHandler *cb,
|
||||
|
||||
Reference in New Issue
Block a user