com php-src: expand IS_ABSOLUTE_PATH on Windows, so then strlen() isn't called twice: Zend/zen d_virtual_cwd.h

From: Date: Fri, 19 Sep 2014 14:30:03 +0000
Subject: com php-src: expand IS_ABSOLUTE_PATH on Windows, so then strlen() isn't called twice: Zend/zen d_virtual_cwd.h
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-81778@lists.php.net to get a copy of this message
Commit: 149db936d43ba31bb41da62b0d26d510f32514ee Author: Anatol Belski <ab@php.net> Fri, 19 Sep 2014 15:44:04 +0200 Parents: 469c9bdb392ab0d8c91d7e2ab5ff93c650489143 Branches: master Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=149db936d43ba31bb41da62b0d26d510f32514ee Log: expand IS_ABSOLUTE_PATH on Windows, so then strlen() isn't called twice Changed paths: M Zend/zend_virtual_cwd.h Diff: diff --git a/Zend/zend_virtual_cwd.h b/Zend/zend_virtual_cwd.h index 3c432de..8bc0d27 100644 --- a/Zend/zend_virtual_cwd.h +++ b/Zend/zend_virtual_cwd.h @@ -70,7 +70,7 @@ typedef unsigned short mode_t; #define IS_UNC_PATH(path, len) \ (len >= 2 && IS_SLASH(path[0]) && IS_SLASH(path[1])) #define IS_ABSOLUTE_PATH(path, len) \ - (len >= 2 && ((isalpha(path[0]) && path[1] == ':') || IS_UNC_PATH(path, len))) + (len >= 2 && ((/* is local */isalpha(path[0]) && path[1] == ':') || /* is UNC */IS_SLASH(path[0]) && IS_SLASH(path[1]))) #elif defined(NETWARE) #ifdef HAVE_DIRENT_H

« previous php.cvs (#81778) next »