Skip to content

Commit 763c4a0

Browse files
CID 315823 truncate on cast
1 parent d71776a commit 763c4a0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

wolfcrypt/src/asn.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14855,7 +14855,7 @@ int wc_ValidateDate(const byte* date, byte format, int dateType)
1485514855

1485614856
ltime = wc_Time(0);
1485714857
#ifndef NO_TIME_SIGNEDNESS_CHECK
14858-
if (sizeof(ltime) == sizeof(word32) && (int)ltime < 0){
14858+
if (sizeof(ltime) == sizeof(word32) && (sword32)ltime < 0){
1485914859
/* A negative response here could be due to a 32-bit time_t
1486014860
* where the year is 2038 or later. */
1486114861
WOLFSSL_MSG("wc_Time failed to return a valid value");

0 commit comments

Comments
 (0)