From: Alan T. DeKok Date: Tue, 26 Oct 2021 12:39:46 +0000 (-0400) Subject: parent from the correct ctx X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=6015738f7a55ec2d6dc0d1bb64d0a890b9217708;p=thirdparty%2Ffreeradius-server.git parent from the correct ctx --- diff --git a/src/protocols/dhcpv6/decode.c b/src/protocols/dhcpv6/decode.c index 12868aa273c..4dd2fa297e6 100644 --- a/src/protocols/dhcpv6/decode.c +++ b/src/protocols/dhcpv6/decode.c @@ -626,7 +626,7 @@ static int decode_test_ctx(void **out, TALLOC_CTX *ctx) test_ctx = talloc_zero(ctx, fr_dhcpv6_decode_ctx_t); if (!test_ctx) return -1; - test_ctx->tmp_ctx = talloc(ctx, uint8_t); + test_ctx->tmp_ctx = talloc(test_ctx, uint8_t); talloc_set_destructor(test_ctx, _test_ctx_free); *out = test_ctx; diff --git a/src/protocols/radius/decode.c b/src/protocols/radius/decode.c index 3bb9a9d1c4f..c4e197ac74c 100644 --- a/src/protocols/radius/decode.c +++ b/src/protocols/radius/decode.c @@ -1810,7 +1810,7 @@ static int decode_test_ctx(void **out, TALLOC_CTX *ctx) test_ctx = talloc_zero(ctx, fr_radius_ctx_t); test_ctx->secret = talloc_strdup(test_ctx, "testing123"); memcpy(test_ctx->vector, vector, sizeof(test_ctx->vector)); - test_ctx->tmp_ctx = talloc_zero(ctx, uint8_t); + test_ctx->tmp_ctx = talloc_zero(test_ctx, uint8_t); talloc_set_destructor(test_ctx, _test_ctx_free); *out = test_ctx;