File tree Expand file tree Collapse file tree 1 file changed +18
-0
lines changed Expand file tree Collapse file tree 1 file changed +18
-0
lines changed Original file line number Diff line number Diff line change @@ -1057,6 +1057,19 @@ local function test_cb(name)
10571057
10581058 gc_collect ()
10591059 assert_nil (pctx .value )
1060+
1061+ do local ctx = {}
1062+ pctx = weak_ptr (ctx )
1063+ assert (set (c , function () end , ctx ))
1064+ end
1065+
1066+ gc_collect ()
1067+ assert_table (pctx .value )
1068+
1069+ c :reset ()
1070+
1071+ gc_collect ()
1072+ assert_nil (pctx .value )
10601073end
10611074
10621075function test_read () test_cb (' readfunction' ) end
@@ -1069,6 +1082,11 @@ function test_fnmatch() test_cb('fnmatch_function') end
10691082function test_chunk_bgn () test_cb (' chunk_bgn_function' ) end
10701083function test_chunk_end () test_cb (' chunk_end_function' ) end
10711084
1085+ if curl .OPT_HSTSREADFUNCTION then
1086+ function test_hstsreadfunction () test_cb (' hstsreadfunction' ) end
1087+ function test_hstswritefunction () test_cb (' hstswritefunction' ) end
1088+ end
1089+
10721090end
10731091
10741092local _ENV = TEST_CASE ' set_slist' if ENABLE then
You can’t perform that action at this time.
0 commit comments