Skip to content

Commit

Permalink
Fix mortal-scalar leak.
Browse files Browse the repository at this point in the history
Code was calling sv_2mortal() to create temps outside of a SAVETMPS/FREETMPS
scope; this leaked certain temp scalars pretty reliably.
  • Loading branch information
stash committed Jul 15, 2011
1 parent fbacb26 commit 197a76f
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions Feersum.xs
Expand Up @@ -1946,8 +1946,6 @@ call_request_callback (struct feer_conn *c)


trace("leaving request callback\n"); trace("leaving request callback\n");
PUTBACK; PUTBACK;
FREETMPS;
LEAVE;


if (request_cb_is_psgi && likely(returned >= 1)) { if (request_cb_is_psgi && likely(returned >= 1)) {
feersum_handle_psgi_response(aTHX_ c, psgi_response, 1); // can_recurse feersum_handle_psgi_response(aTHX_ c, psgi_response, 1); // can_recurse
Expand All @@ -1956,6 +1954,9 @@ call_request_callback (struct feer_conn *c)


c->in_callback--; c->in_callback--;
SvREFCNT_dec(c->self); SvREFCNT_dec(c->self);

FREETMPS;
LEAVE;
} }


static void static void
Expand Down

0 comments on commit 197a76f

Please sign in to comment.