From ed1a6c7893d4b8e41399878fee854bc3acb9486e Mon Sep 17 00:00:00 2001 From: Serhiy Storchaka Date: Mon, 16 Sep 2024 12:17:32 +0300 Subject: [PATCH] Revert "gh-123974: Fix time.get_clock_info() on NetBSD (#123975)" This reverts commit b1d6f8a2ee04215c64aa8752cc515b7e98a08d28. --- Modules/timemodule.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/Modules/timemodule.c b/Modules/timemodule.c index cfbb26b0259504..46f85bc9c30f9c 100644 --- a/Modules/timemodule.c +++ b/Modules/timemodule.c @@ -1509,19 +1509,15 @@ _PyTime_GetThreadTimeWithInfo(PyTime_t *tp, _Py_clock_info_t *info) return -1; } if (info) { + struct timespec res; info->implementation = function; info->monotonic = 1; info->adjustable = 0; - #if defined(__NetBSD__) - info->resolution = 1e-9; - #else - struct timespec res; if (clock_getres(clk_id, &res)) { PyErr_SetFromErrno(PyExc_OSError); return -1; } info->resolution = res.tv_sec + res.tv_nsec * 1e-9; - #endif } if (_PyTime_FromTimespec(tp, &ts) < 0) {