Skip to content

Commit 45ba778

Browse files
Merge pull request #6911 from douzzer/20231025-sp_to_unsigned_bin_len_ct-Wconversion-cast
20231025-sp_to_unsigned_bin_len_ct-Wconversion-cast
2 parents fc858ec + 7821c48 commit 45ba778

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

wolfcrypt/src/sp_int.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17813,7 +17813,7 @@ int sp_to_unsigned_bin_len_ct(const sp_int* a, byte* out, int outSz)
1781317813
d = a->dp[i];
1781417814
/* Place each byte of a digit into the buffer. */
1781517815
for (b = 0; (j >= 0) && (b < SP_WORD_SIZEOF); b++) {
17816-
out[j--] = (byte)(d & mask);
17816+
out[j--] = (byte)((sp_digit)d & mask);
1781717817
d >>= 8;
1781817818
}
1781917819
mask &= (sp_digit)0 - (i < a->used - 1);

0 commit comments

Comments
 (0)