Skip to content

Commit

Permalink
Fixed build error with CMake
Browse files Browse the repository at this point in the history
Explicitly cast `long long` -> `long double` to avoid build warnings

Fixes issue: #1805

Signed-off-by: Eran Ifrah <[email protected]>
  • Loading branch information
eifrah-aws committed Mar 2, 2025
1 parent 3f6581b commit 9f4dec8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/timeout.c
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,7 @@ int getTimeoutFromObjectOrReply(client *c, robj *object, mstime_t *timeout, int
return C_ERR;

ftval *= 1000.0; /* seconds => millisec */
if (ftval > LLONG_MAX) {
if (ftval > (long double)LLONG_MAX) {
addReplyError(c, "timeout is out of range");
return C_ERR;
}
Expand Down

0 comments on commit 9f4dec8

Please sign in to comment.