Fixes for perl 5.36 with multiplicity + memleak in $st->kv methods
I always keep messing up the aTHX_ and pTHX_ stuff because my system perl isn't built with multiplicity, and I still haven't found a satisfactory way of finding SV leaks. Valgrind can't track those :(
This commit is contained in:
parent
1f7e2de9a0
commit
867543267f
6 changed files with 40 additions and 32 deletions
|
|
@ -240,12 +240,12 @@ static SV *fujson_parse(pTHX_ fujson_parse_ctx *ctx) {
|
|||
if (ctx->end - ctx->buf < 4) return NULL;
|
||||
if (memcmp(ctx->buf, "true", 4) != 0) return NULL;
|
||||
ctx->buf += 4;
|
||||
return newSV_true();
|
||||
return &PL_sv_yes;
|
||||
case 'f':
|
||||
if (ctx->end - ctx->buf < 5) return NULL;
|
||||
if (memcmp(ctx->buf, "false", 5) != 0) return NULL;
|
||||
ctx->buf += 5;
|
||||
return newSV_false();
|
||||
return &PL_sv_no;
|
||||
case 'n':
|
||||
if (ctx->end - ctx->buf < 4) return NULL;
|
||||
if (memcmp(ctx->buf, "null", 4) != 0) return NULL;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue