Skip to content

Commit 31c0f6d

Browse files
Have secp256k1_gej_double_var initialize all fields.
Previous behaviour would not initialize r->x and r->y values in the case where infinity is passed in.
1 parent dd6c3de commit 31c0f6d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/group_impl.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -310,7 +310,7 @@ static void secp256k1_gej_double_var(secp256k1_gej *r, const secp256k1_gej *a, s
310310
* point will be gibberish (z = 0 but infinity = 0).
311311
*/
312312
if (a->infinity) {
313-
r->infinity = 1;
313+
secp256k1_gej_set_infinity(r);
314314
if (rzr != NULL) {
315315
secp256k1_fe_set_int(rzr, 1);
316316
}

0 commit comments

Comments
 (0)