summaryrefslogtreecommitdiff
path: root/test_ffi/tests/test.js
diff options
context:
space:
mode:
authorDj <43033058+DjDeveloperr@users.noreply.github.com>2023-04-01 09:26:02 +0530
committerGitHub <noreply@github.com>2023-04-01 09:26:02 +0530
commitc162647020c26de1d27064b488ca11525f1bc4bf (patch)
tree12709a19c838e4a00b65e334dc74e983ace0f0c2 /test_ffi/tests/test.js
parentbafffa95a08765085ab0bb43732d268038a46630 (diff)
fix(ext/ffi): crash when same reference struct is used in two fields (#18531)
fix #17482
Diffstat (limited to 'test_ffi/tests/test.js')
-rw-r--r--test_ffi/tests/test.js3
1 files changed, 2 insertions, 1 deletions
diff --git a/test_ffi/tests/test.js b/test_ffi/tests/test.js
index 788faa93e..5e193e99f 100644
--- a/test_ffi/tests/test.js
+++ b/test_ffi/tests/test.js
@@ -78,6 +78,7 @@ const Point = ["f64", "f64"];
const Size = ["f64", "f64"];
const Rect = ["f64", "f64", "f64", "f64"];
const RectNested = [{ struct: Point }, { struct: Size }];
+const RectNestedCached = [{ struct: Size }, { struct: Size }];
const Mixed = ["u8", "f32", { struct: Rect }, "usize", { struct: ["u32", "u32"] }];
const dylib = Deno.dlopen(libPath, {
@@ -264,7 +265,7 @@ const dylib = Deno.dlopen(libPath, {
result: { struct: RectNested },
},
print_rect: {
- parameters: [{ struct: Rect }],
+ parameters: [{ struct: RectNestedCached }],
result: "void",
},
print_rect_async: {