[php-src] PHP-8.3: Use ZEND_API in zend_hrtime (#13288)

From: Date: Sun, 17 Mar 2024 02:22:57 +0000
Subject: [php-src] PHP-8.3: Use ZEND_API in zend_hrtime (#13288)
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-127755@lists.php.net to get a copy of this message
Author: Bob Weinand (bwoebi) Committer: GitHub (web-flow) Pusher: bwoebi Date: 2024-03-17T03:09:08+01:00 Commit: https://github.com/php/php-src/commit/6c4e3c0f52510eef93edc03a329f9d5c22033ab3 Raw diff: https://github.com/php/php-src/commit/6c4e3c0f52510eef93edc03a329f9d5c22033ab3.diff Use ZEND_API in zend_hrtime (#13288) This allows actually calling zend_hrtime() from extensions on Windows. Signed-off-by: Bob Weinand <bobwei9@hotmail.com> Changed paths: M Zend/zend_hrtime.c M Zend/zend_hrtime.h Diff: diff --git a/Zend/zend_hrtime.c b/Zend/zend_hrtime.c index a28ba3f470508..bcf11964f1cea 100644 --- a/Zend/zend_hrtime.c +++ b/Zend/zend_hrtime.c @@ -31,13 +31,13 @@ # define WIN32_LEAN_AND_MEAN -double zend_hrtime_timer_scale = .0; +ZEND_API double zend_hrtime_timer_scale = .0; #elif ZEND_HRTIME_PLATFORM_APPLE # include <mach/mach_time.h> # include <string.h> -mach_timebase_info_data_t zend_hrtime_timerlib_info = { +ZEND_API mach_timebase_info_data_t zend_hrtime_timerlib_info = { .numer = 0, .denom = 1, }; diff --git a/Zend/zend_hrtime.h b/Zend/zend_hrtime.h index 6bba076738a91..1449c4e443cf2 100644 --- a/Zend/zend_hrtime.h +++ b/Zend/zend_hrtime.h @@ -60,13 +60,13 @@ BEGIN_EXTERN_C() #if ZEND_HRTIME_PLATFORM_WINDOWS -extern double zend_hrtime_timer_scale; +ZEND_API extern double zend_hrtime_timer_scale; #elif ZEND_HRTIME_PLATFORM_APPLE # include <mach/mach_time.h> # include <string.h> -extern mach_timebase_info_data_t zend_hrtime_timerlib_info; +ZEND_API extern mach_timebase_info_data_t zend_hrtime_timerlib_info; #endif

« previous php.cvs (#127755) next »