Skip to content

Commit 1fb46ff

Browse files
committed
Fix second inacurracy in C extension
1 parent c0d37bd commit 1fb46ff

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

pendulum/_extensions/_helpers.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -317,7 +317,7 @@ PyObject* local_time(PyObject *self, PyObject *args) {
317317
}
318318

319319
year = EPOCH_YEAR;
320-
seconds = (int64_t) unix_time;
320+
seconds = (int64_t) floor(unix_time);
321321

322322
// Shift to a base year that is 400-year aligned.
323323
if (seconds >= 0) {

0 commit comments

Comments
 (0)