Skip Menu |

This queue is for tickets about the Digest-BLAKE2 CPAN distribution.

Report information
The Basics
Id: 94112
Status: patched
Priority: 0/
Queue: Digest-BLAKE2

People
Owner: gunya [...] cpan.org
Requestors: rurban [...] x-ray.at
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: 0.01
Fixed in: 0.02



Subject: fix for threaded perls
Subject: Digest-BLAKE2-0.01-thr.patch
diff -bu Digest-BLAKE2-0.01-t_zrk3/lib/Digest/BLAKE2b.xs~ Digest-BLAKE2-0.01-t_zrk3/lib/Digest/BLAKE2b.xs --- Digest-BLAKE2-0.01-t_zrk3/lib/Digest/BLAKE2b.xs~ 2014-03-22 14:23:04.000000000 -0500 +++ Digest-BLAKE2-0.01-t_zrk3/lib/Digest/BLAKE2b.xs 2014-03-22 14:24:09.000000000 -0500 @@ -24,7 +24,7 @@ }; inline static SV * -encode_string(const char *src, enum encode_type type) { +encode_string(pTHX_ const char *src, enum encode_type type) { int encoded_len; switch (type) { @@ -154,5 +154,5 @@ } blake2b_final(state, out, BLAKE2B_OUTBYTES); Safefree(state); - ST(0) = encode_string((char *)out, ix); + ST(0) = encode_string(aTHX_ (char *)out, ix); XSRETURN(1); diff -bu Digest-BLAKE2-0.01-t_zrk3/lib/Digest/BLAKE2s.xs~ Digest-BLAKE2-0.01-t_zrk3/lib/Digest/BLAKE2s.xs --- Digest-BLAKE2-0.01-t_zrk3/lib/Digest/BLAKE2s.xs~ 2014-03-22 14:21:35.000000000 -0500 +++ Digest-BLAKE2-0.01-t_zrk3/lib/Digest/BLAKE2s.xs 2014-03-22 14:22:57.000000000 -0500 @@ -24,7 +24,7 @@ }; inline static SV * -encode_string(const char *src, enum encode_type type) { +encode_string(pTHX_ const char *src, enum encode_type type) { int encoded_len; switch (type) { @@ -154,5 +154,5 @@ } blake2s_final(state, out, BLAKE2S_OUTBYTES); Safefree(state); - ST(0) = encode_string((char *)out, ix); + ST(0) = encode_string(aTHX_ (char *)out, ix); XSRETURN(1);
From: rurban [...] x-ray.at
oops, these XS were generated. better patch attached
Subject: Digest-BLAKE2-0.01-thr.patch
diff -bu Digest-BLAKE2-0.01-7N4L0h/in/src/BLAKE2x.xs~ Digest-BLAKE2-0.01-7N4L0h/in/src/BLAKE2x.xs --- Digest-BLAKE2-0.01-7N4L0h/in/src/BLAKE2x.xs~ 2013-02-09 21:47:42.000000000 -0600 +++ Digest-BLAKE2-0.01-7N4L0h/in/src/BLAKE2x.xs 2014-03-22 14:40:25.000000000 -0500 @@ -24,7 +24,7 @@ }; inline static SV * -encode_string(const char *src, enum encode_type type) { +encode_string(pTHX_ const char *src, enum encode_type type) { int encoded_len; switch (type) { @@ -154,5 +154,5 @@ } blake2x_final(state, out, BLAKE2x_OUTBYTES); Safefree(state); - ST(0) = encode_string((char *)out, ix); + ST(0) = encode_string(aTHX_ (char *)out, ix); XSRETURN(1);
Thank you for the patch. I applied it and released version 0.02.