mpi/ec: fix when 'unsigned long' is 32-bit but limb size is 64-bit

Authored by jukivili on Jan 6 2018, 6:25 PM.

Description

mpi/ec: fix when 'unsigned long' is 32-bit but limb size is 64-bit

* mpi/ec.c (ec_addm_25519, ec_subm_25519, ec_mulm_25519): Cast '1' to
mpi_limb_t before left shift.

Patch fixes mpi/ec.c compiler warnings and failing tests cases on
Win64.

  • Signed-off-by: Jussi Kivilinna <jussi.kivilinna@iki.fi>

Details

Committed
jukiviliJan 9 2018, 5:36 PM
Parents
rCd2feba84e172: tests: Add another test case to keygrip.c
Branches
Unknown
Tags
Unknown