@@ -893,7 +893,7 @@ static inline void kill_all_lockers(struct flock *mem_usage_check)
893
893
}
894
894
#endif
895
895
896
- static inline int accel_is_inactive (void )
896
+ static inline bool accel_is_inactive (void )
897
897
{
898
898
#ifdef ZEND_WIN32
899
899
/* on Windows, we don't need kill_all_lockers() because SAPIs
@@ -904,7 +904,7 @@ static inline int accel_is_inactive(void)
904
904
provide us with the PID of locker processes) */
905
905
906
906
if (LOCKVAL (mem_usage ) == 0 ) {
907
- return SUCCESS ;
907
+ return true ;
908
908
}
909
909
#else
910
910
struct flock mem_usage_check ;
@@ -916,10 +916,10 @@ static inline int accel_is_inactive(void)
916
916
mem_usage_check .l_pid = -1 ;
917
917
if (fcntl (lock_file , F_GETLK , & mem_usage_check ) == -1 ) {
918
918
zend_accel_error (ACCEL_LOG_DEBUG , "UpdateC: %s (%d)" , strerror (errno ), errno );
919
- return FAILURE ;
919
+ return false ;
920
920
}
921
921
if (mem_usage_check .l_type == F_UNLCK ) {
922
- return SUCCESS ;
922
+ return true ;
923
923
}
924
924
925
925
if (ZCG (accel_directives ).force_restart_timeout
@@ -928,11 +928,11 @@ static inline int accel_is_inactive(void)
928
928
zend_accel_error (ACCEL_LOG_WARNING , "Forced restart at %ld (after " ZEND_LONG_FMT " seconds), locked by %d" , (long )time (NULL ), ZCG (accel_directives ).force_restart_timeout , mem_usage_check .l_pid );
929
929
kill_all_lockers (& mem_usage_check );
930
930
931
- return FAILURE ; /* next request should be able to restart it */
931
+ return false ; /* next request should be able to restart it */
932
932
}
933
933
#endif
934
934
935
- return FAILURE ;
935
+ return false ;
936
936
}
937
937
938
938
static int zend_get_stream_timestamp (const char * filename , zend_stat_t * statbuf )
@@ -2687,7 +2687,7 @@ zend_result accel_activate(INIT_FUNC_ARGS)
2687
2687
if (ZCSG (restart_pending )) {
2688
2688
zend_shared_alloc_lock ();
2689
2689
if (ZCSG (restart_pending )) { /* check again, to ensure that the cache wasn't already cleaned by another process */
2690
- if (accel_is_inactive () == SUCCESS ) {
2690
+ if (accel_is_inactive ()) {
2691
2691
zend_accel_error (ACCEL_LOG_DEBUG , "Restarting!" );
2692
2692
ZCSG (restart_pending ) = false;
2693
2693
switch ZCSG (restart_reason ) {
0 commit comments