Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

stack overflow in JS_GetPropertyInternal #32

Closed
apascovici opened this issue Nov 8, 2020 · 1 comment
Closed

stack overflow in JS_GetPropertyInternal #32

apascovici opened this issue Nov 8, 2020 · 1 comment

Comments

@apascovici
Copy link

[again, needs CONFIG_ASAN=y in Makefile]
Repro:
./qjs JS_GetPropertyInternal.js.TXT

POC fix:
diff --git a/quickjs.c b/quickjs.c
index a39ff8f..6a2d259 100644
--- a/quickjs.c
+++ b/quickjs.c
@@ -39079,6 +39079,7 @@ static int64_t JS_FlattenIntoArray(JSContext *ctx, JSValueConst target,

  • if (js_check_stack_overflow(ctx->rt, 0)) return -1;

Attached file:
JS_GetPropertyInternal.js.TXT

@bellard
Copy link
Owner

bellard commented Mar 27, 2021

fixed

@bellard bellard closed this as completed Mar 27, 2021
GerHobbelt pushed a commit to GerHobbelt/quickjs that referenced this issue Oct 17, 2023
* failing memory test

* pass strings on the heap
TooTallNate pushed a commit to TooTallNate/quickjs that referenced this issue Dec 18, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants