nlopess         Tue Sep 23 15:22:05 2008 UTC

  Modified files:              
    /ZendEngine2        zend_constants.c 
    /php-src/ext/iconv  iconv.c 
    /php-src/ext/pcre   php_pcre.c 
    /php-src/ext/standard       array.c base64.c image.c versioning.c 
    /php-src/main       rfc1867.c 
    /php-src/main/streams       glob_wrapper.c 
  Log:
  MFB: clean some dead code
  
http://cvs.php.net/viewvc.cgi/ZendEngine2/zend_constants.c?r1=1.113&r2=1.114&diff_format=u
Index: ZendEngine2/zend_constants.c
diff -u ZendEngine2/zend_constants.c:1.113 ZendEngine2/zend_constants.c:1.114
--- ZendEngine2/zend_constants.c:1.113  Tue Aug 12 17:15:59 2008
+++ ZendEngine2/zend_constants.c        Tue Sep 23 15:22:05 2008
@@ -17,7 +17,7 @@
    +----------------------------------------------------------------------+
 */
 
-/* $Id: zend_constants.c,v 1.113 2008/08/12 17:15:59 felipe Exp $ */
+/* $Id: zend_constants.c,v 1.114 2008/09/23 15:22:05 nlopess Exp $ */
 
 #include "zend.h"
 #include "zend_constants.h"
@@ -458,7 +458,6 @@
                                        name = constant_name;
                                        name_len = const_name_len;
                                        efree(class_name.v);
-                                       retval = 1;
                                        return zend_u_get_constant(type, name, 
name_len, result TSRMLS_CC);
                                }
                                if ((flags & ZEND_FETCH_CLASS_SILENT) == 0) {
http://cvs.php.net/viewvc.cgi/php-src/ext/iconv/iconv.c?r1=1.165&r2=1.166&diff_format=u
Index: php-src/ext/iconv/iconv.c
diff -u php-src/ext/iconv/iconv.c:1.165 php-src/ext/iconv/iconv.c:1.166
--- php-src/ext/iconv/iconv.c:1.165     Wed May 21 15:03:11 2008
+++ php-src/ext/iconv/iconv.c   Tue Sep 23 15:22:05 2008
@@ -18,7 +18,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: iconv.c,v 1.165 2008/05/21 15:03:11 tony2001 Exp $ */
+/* $Id: iconv.c,v 1.166 2008/09/23 15:22:05 nlopess Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include "config.h"
@@ -1357,7 +1357,6 @@
                                                char_cnt -= 3;
                                        }
                                }
-                               prev_in_left = in_left;
 
                                smart_str_appendl(pretval, "?=", sizeof("?=") - 
1);
                                char_cnt -= 2;
http://cvs.php.net/viewvc.cgi/php-src/ext/pcre/php_pcre.c?r1=1.240&r2=1.241&diff_format=u
Index: php-src/ext/pcre/php_pcre.c
diff -u php-src/ext/pcre/php_pcre.c:1.240 php-src/ext/pcre/php_pcre.c:1.241
--- php-src/ext/pcre/php_pcre.c:1.240   Tue Sep  2 19:13:24 2008
+++ php-src/ext/pcre/php_pcre.c Tue Sep 23 15:22:05 2008
@@ -16,7 +16,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: php_pcre.c,v 1.240 2008/09/02 19:13:24 nlopess Exp $ */
+/* $Id: php_pcre.c,v 1.241 2008/09/23 15:22:05 nlopess Exp $ */
 
 /*  TODO
  *  php_pcre_replace_impl():
@@ -1023,7 +1023,6 @@
                                } else {
                                        esc_match = "";
                                        esc_match_len = 0;
-                                       match_len = 0;
                                }
                                smart_str_appendl(&code, esc_match, 
esc_match_len);
 
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/array.c?r1=1.463&r2=1.464&diff_format=u
Index: php-src/ext/standard/array.c
diff -u php-src/ext/standard/array.c:1.463 php-src/ext/standard/array.c:1.464
--- php-src/ext/standard/array.c:1.463  Fri Aug 29 02:48:28 2008
+++ php-src/ext/standard/array.c        Tue Sep 23 15:22:05 2008
@@ -21,7 +21,7 @@
    +----------------------------------------------------------------------+
 */
 
-/* $Id: array.c,v 1.463 2008/08/29 02:48:28 felipe Exp $ */
+/* $Id: array.c,v 1.464 2008/09/23 15:22:05 nlopess Exp $ */
 
 #include "php.h"
 #include "php_ini.h"
@@ -3574,7 +3574,6 @@
        } else if (behavior & DIFF_ASSOC) { /* triggered also if DIFF_KEY */
                /* DIFF_KEY is subset of DIFF_ASSOC. When having the former
                 * no comparison of the data is done (part of DIFF_ASSOC) */
-               diff_key_compare_func = php_array_key_compare;
 
                if (data_compare_type == DIFF_COMP_DATA_INTERNAL && 
key_compare_type == DIFF_COMP_KEY_INTERNAL) {
                        /* array_diff_assoc() or array_diff_key() */
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/base64.c?r1=1.55&r2=1.56&diff_format=u
Index: php-src/ext/standard/base64.c
diff -u php-src/ext/standard/base64.c:1.55 php-src/ext/standard/base64.c:1.56
--- php-src/ext/standard/base64.c:1.55  Mon Dec 31 07:12:15 2007
+++ php-src/ext/standard/base64.c       Tue Sep 23 15:22:05 2008
@@ -15,7 +15,7 @@
    | Author: Jim Winstead <[EMAIL PROTECTED]>                                  
|
    +----------------------------------------------------------------------+
  */
-/* $Id: base64.c,v 1.55 2007/12/31 07:12:15 sebastian Exp $ */
+/* $Id: base64.c,v 1.56 2008/09/23 15:22:05 nlopess Exp $ */
 
 #include <string.h>
 
@@ -190,7 +190,7 @@
                case 2:
                        k++;
                case 3:
-                       result[k++] = 0;
+                       result[k] = 0;
                }
        }
        if(ret_length) {
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/image.c?r1=1.133&r2=1.134&diff_format=u
Index: php-src/ext/standard/image.c
diff -u php-src/ext/standard/image.c:1.133 php-src/ext/standard/image.c:1.134
--- php-src/ext/standard/image.c:1.133  Sat May 24 11:53:35 2008
+++ php-src/ext/standard/image.c        Tue Sep 23 15:22:05 2008
@@ -17,7 +17,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: image.c,v 1.133 2008/05/24 11:53:35 helly Exp $ */
+/* $Id: image.c,v 1.134 2008/09/23 15:22:05 nlopess Exp $ */
 
 #include "php.h"
 #include <stdio.h>
@@ -653,7 +653,7 @@
        }
 
        /* Collect bit depth info */
-       highest_bit_depth = bit_depth = 0;
+       highest_bit_depth = 0;
        for (i = 0; i < result->channels; i++) {
                bit_depth = php_stream_getc(stream); /* Ssiz[i] */
                bit_depth++;
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/versioning.c?r1=1.26&r2=1.27&diff_format=u
Index: php-src/ext/standard/versioning.c
diff -u php-src/ext/standard/versioning.c:1.26 
php-src/ext/standard/versioning.c:1.27
--- php-src/ext/standard/versioning.c:1.26      Mon Dec 31 07:12:16 2007
+++ php-src/ext/standard/versioning.c   Tue Sep 23 15:22:05 2008
@@ -16,7 +16,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: versioning.c,v 1.26 2007/12/31 07:12:16 sebastian Exp $ */
+/* $Id: versioning.c,v 1.27 2008/09/23 15:22:05 nlopess Exp $ */
 
 #include <stdio.h>
 #include <sys/types.h>
@@ -45,7 +45,7 @@
     p = version;
     q = buf;
     *q++ = lp = *p++;
-    lq = '\0';
+
     while (*p) {
 /*  s/[-_+]/./g;
  *  s/([^\d\.])([^\D\.])/$1.$2/g;
@@ -55,22 +55,22 @@
 #define isndig(x) (!isdigit(x)&&(x)!='.')
 #define isspecialver(x) ((x)=='-'||(x)=='_'||(x)=='+')
 
-        lq = *(q - 1);
+               lq = *(q - 1);
                if (isspecialver(*p)) {
                        if (lq != '.') {
-                               lq = *q++ = '.';
+                               *q++ = '.';
                        }
                } else if ((isndig(lp) && isdig(*p)) || (isdig(lp) && 
isndig(*p))) {
                        if (lq != '.') {
                                *q++ = '.';
                        }
-                       lq = *q++ = *p;
+                       *q++ = *p;
                } else if (!isalnum(*p)) {
                        if (lq != '.') {
-                               lq = *q++ = '.';
+                               *q++ = '.';
                        }
                } else {
-                       lq = *q++ = *p;
+                       *q++ = *p;
                }
                lp = *p++;
     }
http://cvs.php.net/viewvc.cgi/php-src/main/rfc1867.c?r1=1.202&r2=1.203&diff_format=u
Index: php-src/main/rfc1867.c
diff -u php-src/main/rfc1867.c:1.202 php-src/main/rfc1867.c:1.203
--- php-src/main/rfc1867.c:1.202        Thu Sep 18 19:44:01 2008
+++ php-src/main/rfc1867.c      Tue Sep 23 15:22:05 2008
@@ -17,7 +17,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: rfc1867.c,v 1.202 2008/09/18 19:44:01 lbarnaud Exp $ */
+/* $Id: rfc1867.c,v 1.203 2008/09/23 15:22:05 nlopess Exp $ */
 
 /*
  *  This product includes software developed by the Apache Group
@@ -189,7 +189,8 @@
                        index = NULL;
                }       
        }
-       *s++='\0';
+
+       *s = '\0';
 }
 
 
@@ -784,7 +785,7 @@
                }
        }
 
-       *resp++ = '\0';
+       *resp = '\0';
        return result;
 }
 
http://cvs.php.net/viewvc.cgi/php-src/main/streams/glob_wrapper.c?r1=1.8&r2=1.9&diff_format=u
Index: php-src/main/streams/glob_wrapper.c
diff -u php-src/main/streams/glob_wrapper.c:1.8 
php-src/main/streams/glob_wrapper.c:1.9
--- php-src/main/streams/glob_wrapper.c:1.8     Wed Jan 30 23:43:05 2008
+++ php-src/main/streams/glob_wrapper.c Tue Sep 23 15:22:05 2008
@@ -16,7 +16,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: glob_wrapper.c,v 1.8 2008/01/30 23:43:05 helly Exp $ */
+/* $Id: glob_wrapper.c,v 1.9 2008/09/23 15:22:05 nlopess Exp $ */
 
 #include "php.h"
 #include "php_streams_int.h"
@@ -209,7 +209,7 @@
                int options, char **opened_path, php_stream_context *context 
STREAMS_DC TSRMLS_DC)
 {
        glob_s_t *pglob;
-       int ret, path_len;
+       int ret;
        char *tmp, *pos;
 
        if (((options & STREAM_DISABLE_OPEN_BASEDIR) == 0) && 
php_check_open_basedir(path TSRMLS_CC)) {
@@ -218,12 +218,9 @@
 
        if (!strncmp(path, "glob://", sizeof("glob://")-1)) {
                path += sizeof("glob://")-1;
-               path_len = strlen(path);
                if (opened_path) {
-                       *opened_path = estrndup(path, path_len);
+                       *opened_path = estrdup(path);
                }
-       } else {
-               path_len = strlen(path);
        }
 
        pglob = ecalloc(sizeof(*pglob), 1);

-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to