[PHP-CVS] cvs: php-src /ext/standard/tests/strings count_chars.phpt

2007-07-11 Thread Johannes Schl
johannesWed Jul 11 15:46:20 2007 UTC

  Modified files:  
/php-src/ext/standard/tests/strings count_chars.phpt 
  Log:
  Fix test for unicode mode
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/strings/count_chars.phpt?r1=1.2r2=1.3diff_format=u
Index: php-src/ext/standard/tests/strings/count_chars.phpt
diff -u php-src/ext/standard/tests/strings/count_chars.phpt:1.2 
php-src/ext/standard/tests/strings/count_chars.phpt:1.3
--- php-src/ext/standard/tests/strings/count_chars.phpt:1.2 Wed May 19 
08:45:23 2004
+++ php-src/ext/standard/tests/strings/count_chars.phpt Wed Jul 11 15:46:20 2007
@@ -4,15 +4,80 @@
 ?php
 $s = het leven is net erwtensoep - je kunt er geen touw aan vastknopen;
 for($i=0; $i3; $i++) {
-   echo implode(count_chars($s, $i)).\n;
+   $c = count_chars($s, $i);
+   if ($i == 1) {
+   print_r($c);
+   } else {
+   echo implode($c),\n;
+   }
 }
+
 echo $a = count_chars($s, 3), \n;
-echo (int) strlen(count_chars($s, 4)) == 256-strlen($a),\n;
+var_dump((int) strlen(count_chars($s, 4)) == 256-strlen($a));
 
 ?
 --EXPECT--
 
12100030001202108320236222
-12131221832236222
+Array
+(
+[32] = 12
+[45] = 1
+[97] = 3
+[101] = 12
+[103] = 1
+[104] = 1
+[105] = 1
+[106] = 1
+[107] = 2
+[108] = 1
+[110] = 8
+[111] = 3
+[112] = 2
+[114] = 2
+[115] = 3
+[116] = 6
+[117] = 2
+[118] = 2
+[119] = 2
+)
 
0
  -aeghijklnoprstuvw
-1
+bool(true)
+--UEXPECTF--
+Warning: count_chars(): Only mode=1 is supported with Unicode strings in %s on 
line %d
+
+Warning: implode(): Argument to implode must be an array in %s on line %d
+
+Array
+(
+[h] = 1
+[e] = 12
+[t] = 6
+[ ] = 12
+[l] = 1
+[v] = 2
+[n] = 8
+[i] = 1
+[s] = 3
+[r] = 2
+[w] = 2
+[o] = 3
+[p] = 2
+[-] = 1
+[j] = 1
+[k] = 2
+[u] = 2
+[g] = 1
+[a] = 3
+)
+
+Warning: count_chars(): Only mode=1 is supported with Unicode strings in %s on 
line %d
+
+Warning: implode(): Argument to implode must be an array in %s on line %d
+
+
+Warning: count_chars(): Only mode=1 is supported with Unicode strings in %s on 
line %d
+
+
+Warning: count_chars(): Only mode=1 is supported with Unicode strings in %s on 
line %d
+bool(false)

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



[PHP-CVS] cvs: php-src / acinclude.m4 /ext/mbstring mbstring.c /ext/standard basic_functions.c mail.c php_mail.h /main config.w32.h main.c /win32/build config.w32.h.in

2007-07-11 Thread Johannes Schl
johannesWed Jul 11 17:39:04 2007 UTC

  Modified files:  
/php-srcacinclude.m4 
/php-src/ext/mbstring   mbstring.c 
/php-src/ext/standard   basic_functions.c mail.c php_mail.h 
/php-src/main   config.w32.h main.c 
/php-src/win32/buildconfig.w32.h.in 
  Log:
  - Always enable mail() function
  
http://cvs.php.net/viewvc.cgi/php-src/acinclude.m4?r1=1.373r2=1.374diff_format=u
Index: php-src/acinclude.m4
diff -u php-src/acinclude.m4:1.373 php-src/acinclude.m4:1.374
--- php-src/acinclude.m4:1.373  Wed Jul 11 10:35:47 2007
+++ php-src/acinclude.m4Wed Jul 11 17:39:04 2007
@@ -1,5 +1,5 @@
 dnl
-dnl $Id: acinclude.m4,v 1.373 2007/07/11 10:35:47 jani Exp $
+dnl $Id: acinclude.m4,v 1.374 2007/07/11 17:39:04 johannes Exp $
 dnl
 dnl This file contains local autoconf functions.
 dnl
@@ -1991,9 +1991,6 @@
 AC_DEFUN([PHP_PROG_SENDMAIL], [
   PHP_ALT_PATH=/usr/bin:/usr/sbin:/usr/etc:/etc:/usr/ucblib:/usr/lib
   AC_PATH_PROG(PROG_SENDMAIL, sendmail,[], $PATH:$PHP_ALT_PATH)
-  if test -n $PROG_SENDMAIL; then
-AC_DEFINE(HAVE_SENDMAIL,1,[whether you have sendmail])
-  fi
   PHP_SUBST(PROG_SENDMAIL)
 ])
 
http://cvs.php.net/viewvc.cgi/php-src/ext/mbstring/mbstring.c?r1=1.268r2=1.269diff_format=u
Index: php-src/ext/mbstring/mbstring.c
diff -u php-src/ext/mbstring/mbstring.c:1.268 
php-src/ext/mbstring/mbstring.c:1.269
--- php-src/ext/mbstring/mbstring.c:1.268   Wed Apr  4 15:23:09 2007
+++ php-src/ext/mbstring/mbstring.c Wed Jul 11 17:39:04 2007
@@ -17,7 +17,7 @@
+--+
  */
 
-/* $Id: mbstring.c,v 1.268 2007/04/04 15:23:09 masugata Exp $ */
+/* $Id: mbstring.c,v 1.269 2007/07/11 17:39:04 johannes Exp $ */
 
 /*
  * PHP 4 Multibyte String module mbstring
@@ -3317,7 +3317,6 @@
 /* {{{ proto int mb_send_mail(string to, string subject, string message [, 
string additional_headers [, string additional_parameters]])
  *  Sends an email message with MIME scheme
  */
-#if HAVE_SENDMAIL
 
 #define SKIP_LONG_HEADER_SEP_MBSTRING(str, pos)
\
if (str[pos] == '\r'  str[pos + 1] == '\n'  (str[pos + 2] == ' ' || 
str[pos + 2] == '\t')) {\
@@ -3821,16 +3820,6 @@
 #undef PHP_MBSTR_MAIL_MIME_HEADER2
 #undef PHP_MBSTR_MAIL_MIME_HEADER3
 #undef PHP_MBSTR_MAIL_MIME_HEADER4
-
-#else  /* HAVE_SENDMAIL */
-
-PHP_FUNCTION(mb_send_mail)
-{
-   RETURN_FALSE;
-}
-
-#endif /* HAVE_SENDMAIL */
-
 /* }}} */
 
 /* {{{ proto mixed mb_get_info([string type])
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/basic_functions.c?r1=1.863r2=1.864diff_format=u
Index: php-src/ext/standard/basic_functions.c
diff -u php-src/ext/standard/basic_functions.c:1.863 
php-src/ext/standard/basic_functions.c:1.864
--- php-src/ext/standard/basic_functions.c:1.863Wed Jul 11 15:52:44 2007
+++ php-src/ext/standard/basic_functions.c  Wed Jul 11 17:39:04 2007
@@ -17,7 +17,7 @@
+--+
  */
 
-/* $Id: basic_functions.c,v 1.863 2007/07/11 15:52:44 dmitry Exp $ */
+/* $Id: basic_functions.c,v 1.864 2007/07/11 17:39:04 johannes Exp $ */
 
 #include php.h
 #include php_streams.h
@@ -1816,7 +1816,6 @@
 #endif
 /* }}} */
 /* {{{ mail.c */
-#ifdef HAVE_SENDMAIL
 static
 ZEND_BEGIN_ARG_INFO(arginfo_ezmlm_hash, 0)
ZEND_ARG_INFO(0, addr)
@@ -1830,7 +1829,6 @@
ZEND_ARG_INFO(0, additional_headers)
ZEND_ARG_INFO(0, additional_parameters)
 ZEND_END_ARG_INFO()
-#endif
 /* }}} */
 /* {{{ math.c */
 static
@@ -3693,10 +3691,8 @@
PHP_FALIAS(diskfreespace,   disk_free_space,
arginfo_disk_free_space)
 
/* functions from mail.c */
-#ifdef HAVE_SENDMAIL
PHP_FE(mail,
arginfo_mail)
PHP_FE(ezmlm_hash,  
arginfo_ezmlm_hash)
-#endif
 
/* functions from syslog.c */
 #ifdef HAVE_SYSLOG_H
@@ -4944,14 +4940,9 @@
 
case 1: /*send an email */
{
-#if HAVE_SENDMAIL
if (!php_mail(opt, PHP error_log message, 
message, headers, NULL TSRMLS_CC)) {
return FAILURE;
}
-#else
-   php_error_docref(NULL TSRMLS_CC, E_WARNING, 
Mail option not available!);
-   return FAILURE;
-#endif
}
break;
 
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/mail.c?r1=1.93r2=1.94diff_format=u
Index: php-src/ext/standard/mail.c
diff -u php-src/ext/standard/mail.c:1.93 php-src/ext/standard/mail.c:1.94
--- 

[PHP-CVS] cvs: php-src(PHP_5_2) / README.CVS-RULES

2007-07-12 Thread Johannes Schl
johannesThu Jul 12 23:44:43 2007 UTC

  Modified files:  (Branch: PHP_5_2)
/php-srcREADME.CVS-RULES 
  Log:
  MFH: - Mention [DOC] tag in the README
  - PHP_5_1 is closed meanwhile
  - Fixed a small typo
  
http://cvs.php.net/viewvc.cgi/php-src/README.CVS-RULES?r1=1.18.2.1.2.1r2=1.18.2.1.2.2diff_format=u
Index: php-src/README.CVS-RULES
diff -u php-src/README.CVS-RULES:1.18.2.1.2.1 
php-src/README.CVS-RULES:1.18.2.1.2.2
--- php-src/README.CVS-RULES:1.18.2.1.2.1   Sun May 21 09:12:34 2006
+++ php-src/README.CVS-RULESThu Jul 12 23:44:43 2007
@@ -39,9 +39,7 @@
 PHP_5_2  Is used to release the PHP 5.2.x series. Only minor feature
  enhancements may go in here, but please keep that as infrequent as
  possible.
-PHP_5_1  Is used to release the PHP 5.1.x series. Only bugfixes are permitted
- on this branch (Consult the releasemaster prior to commit).
-PHP_5_0  This branch is closed.
+PHP_5_1  This branch is closed.
 PHP_4_4  Is used to release the PHP 4.4.x series. Only bugfixes are permitted
  on this branch (Consult the releasemaster prior to commit).
 PHP_4_3  This branch is closed.
@@ -100,9 +98,13 @@
 
 The # lines will be omitted from the ChangeLog automagically.
 
+Use the [DOC] tag in your log message whenever you feel that your changes
+imply a documentation modification. The php-doc team will automatically
+get notified about your commit through the php-doc mailing list.
+
 If you fix some bugs, you should note the bug ID numbers in your
 commit message. Bug ID should be prefixed by # for easier access to
-bug report when developers are browsing CVS via. LXR or Bonsai.
+bug report when developers are browsing CVS via LXR or Bonsai.
 
 Example:
 

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



[PHP-CVS] cvs: php-src / README.CVS-RULES

2007-07-12 Thread Johannes Schl
johannesThu Jul 12 23:44:30 2007 UTC

  Modified files:  
/php-srcREADME.CVS-RULES 
  Log:
  - Mention [DOC] tag in the README
  - PHP_5_1 is closed meanwhile
  - Fixed a small typo
  
http://cvs.php.net/viewvc.cgi/php-src/README.CVS-RULES?r1=1.20r2=1.21diff_format=u
Index: php-src/README.CVS-RULES
diff -u php-src/README.CVS-RULES:1.20 php-src/README.CVS-RULES:1.21
--- php-src/README.CVS-RULES:1.20   Sun May 21 09:12:41 2006
+++ php-src/README.CVS-RULESThu Jul 12 23:44:30 2007
@@ -39,9 +39,7 @@
 PHP_5_2  Is used to release the PHP 5.2.x series. Only minor feature
  enhancements may go in here, but please keep that as infrequent as
  possible.
-PHP_5_1  Is used to release the PHP 5.1.x series. Only bugfixes are permitted
- on this branch (Consult the releasemaster prior to commit).
-PHP_5_0  This branch is closed.
+PHP_5_1  This branch is closed.
 PHP_4_4  Is used to release the PHP 4.4.x series. Only bugfixes are permitted
  on this branch (Consult the releasemaster prior to commit).
 PHP_4_3  This branch is closed.
@@ -100,9 +98,13 @@
 
 The # lines will be omitted from the ChangeLog automagically.
 
+Use the [DOC] tag in your log message whenever you feel that your changes
+imply a documentation modification. The php-doc team will automatically
+get notified about your commit through the php-doc mailing list.
+
 If you fix some bugs, you should note the bug ID numbers in your
 commit message. Bug ID should be prefixed by # for easier access to
-bug report when developers are browsing CVS via. LXR or Bonsai.
+bug report when developers are browsing CVS via LXR or Bonsai.
 
 Example:
 

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



[PHP-CVS] cvs: php-src(PHP_4_4) / README.CVS-RULES

2007-07-12 Thread Johannes Schl
johannesThu Jul 12 23:44:50 2007 UTC

  Modified files:  (Branch: PHP_4_4)
/php-srcREADME.CVS-RULES 
  Log:
  MFH: - Mention [DOC] tag in the README
  - PHP_5_1 is closed meanwhile
  - Fixed a small typo
  
http://cvs.php.net/viewvc.cgi/php-src/README.CVS-RULES?r1=1.16.2.2.2.1r2=1.16.2.2.2.2diff_format=u
Index: php-src/README.CVS-RULES
diff -u php-src/README.CVS-RULES:1.16.2.2.2.1 
php-src/README.CVS-RULES:1.16.2.2.2.2
--- php-src/README.CVS-RULES:1.16.2.2.2.1   Sun May 21 09:10:02 2006
+++ php-src/README.CVS-RULESThu Jul 12 23:44:50 2007
@@ -39,8 +39,7 @@
 PHP_5_2  Is used to release the PHP 5.2.x series. Only minor feature
  enhancements may go in here, but please keep that as infrequent as
  possible.
-PHP_5_1  Is used to release the PHP 5.1.x series. Only bugfixes are permitted
- on this branch (Consult the releasemaster prior to commit).
+PHP_5_1  This branch is closed.
 PHP_4_4  Is used to release the PHP 4.4.x series. Only bugfixes are permitted
  on this branch (Consult the releasemaster prior to commit).
 PHP_4_3  This branch is closed.
@@ -99,9 +98,13 @@
 
 The # lines will be omitted from the ChangeLog automagically.
 
+Use the [DOC] tag in your log message whenever you feel that your changes
+imply a documentation modification. The php-doc team will automatically
+get notified about your commit through the php-doc mailing list.
+
 If you fix some bugs, you should note the bug ID numbers in your
 commit message. Bug ID should be prefixed by # for easier access to
-bug report when developers are browsing CVS via. LXR or Bonsai.
+bug report when developers are browsing CVS via LXR or Bonsai.
 
 Example:
 

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



[PHP-CVS] cvs: php-src / NEWS

2007-07-24 Thread Johannes Schl
johannesTue Jul 24 23:25:48 2007 UTC

  Modified files:  
/php-srcNEWS 
  Log:
  - These functions where MFHd 1 year ago
  
http://cvs.php.net/viewvc.cgi/php-src/NEWS?r1=1.2147r2=1.2148diff_format=u
Index: php-src/NEWS
diff -u php-src/NEWS:1.2147 php-src/NEWS:1.2148
--- php-src/NEWS:1.2147 Thu Jul 12 09:23:47 2007
+++ php-src/NEWSTue Jul 24 23:25:48 2007
@@ -50,8 +50,6 @@
 - Added E_STRICT to E_ALL. (Dmitry)
 - Added an optional parameter to strstr() and stristr() for retrieval of either
   the part of haystack before or after first occurence of needle. (Johannes)
-- Added possibility to check in which extension an internal function was
-  defined using reflection API. (Johannes)
 - Added streams features:
   . Context parameter for copy() function. (Sara)
   . Second optional parameter to stream_context_create() to

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



[PHP-CVS] cvs: php-src(PHP_5_2) / NEWS

2007-07-31 Thread Johannes Schl
johannesTue Jul 31 22:47:43 2007 UTC

  Modified files:  (Branch: PHP_5_2)
/php-srcNEWS 
  Log:
  - BFN
  
  
http://cvs.php.net/viewvc.cgi/php-src/NEWS?r1=1.2027.2.547.2.867r2=1.2027.2.547.2.868diff_format=u
Index: php-src/NEWS
diff -u php-src/NEWS:1.2027.2.547.2.867 php-src/NEWS:1.2027.2.547.2.868
--- php-src/NEWS:1.2027.2.547.2.867 Tue Jul 31 19:21:08 2007
+++ php-src/NEWSTue Jul 31 22:47:43 2007
@@ -185,6 +185,8 @@
   copying). (Dmitry)
 - Fixed bug #41350 (my_thread_global_end() error during request shutdown
   on Windows). (Scott, Andrey)
+- Fixed bug #41278 (get_loaded_extensions() should list Zend extensions).
+  (Johannes)
 - Fixed bug #41127 (Memory leak in ldap_{first|next}_attribute functions).
   (Jani)
 - Fixed bug #40757 (get_object_vars get nothing in child class). (Dmitry)

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



[PHP-CVS] cvs: php-src(PHP_5_2) /main main.c

2007-08-01 Thread Johannes Schl
johannesWed Aug  1 12:49:34 2007 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/main   main.c 
  Log:
  - MFH: Fix #42164 Internal Sendmail Support is ALWAYS disabled
  
http://cvs.php.net/viewvc.cgi/php-src/main/main.c?r1=1.640.2.23.2.49r2=1.640.2.23.2.50diff_format=u
Index: php-src/main/main.c
diff -u php-src/main/main.c:1.640.2.23.2.49 php-src/main/main.c:1.640.2.23.2.50
--- php-src/main/main.c:1.640.2.23.2.49 Tue Jul 24 20:32:32 2007
+++ php-src/main/main.c Wed Aug  1 12:49:34 2007
@@ -18,7 +18,7 @@
+--+
 */
 
-/* $Id: main.c,v 1.640.2.23.2.49 2007/07/24 20:32:32 tony2001 Exp $ */
+/* $Id: main.c,v 1.640.2.23.2.50 2007/08/01 12:49:34 johannes Exp $ */
 
 /* {{{ includes
  */
@@ -314,6 +314,8 @@
 
 #if defined(PHP_PROG_SENDMAIL)  !defined(NETWARE)
 #  define DEFAULT_SENDMAIL_PATH PHP_PROG_SENDMAIL  -t -i 
+#elif defined(PHP_WIN32)
+#  define DEFAULT_SENDMAIL_PATH NULL
 #else
 #  define DEFAULT_SENDMAIL_PATH /usr/sbin/sendmail -t -i 
 #endif

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



[PHP-CVS] cvs: php-src /tests/lang 041.phpt 042.phpt 043.phpt 044.phpt ZendEngine2 zend_language_parser.y

2007-08-02 Thread Johannes Schl
johannesThu Aug  2 21:53:53 2007 UTC

  Added files: 
/php-src/tests/lang 041.phpt 042.phpt 043.phpt 044.phpt 

  Modified files:  
/ZendEngine2zend_language_parser.y 
  Log:
  - Add possibility to call static class members using variables (Etienne 
Kneuss)
  
http://cvs.php.net/viewvc.cgi/ZendEngine2/zend_language_parser.y?r1=1.186r2=1.187diff_format=u
Index: ZendEngine2/zend_language_parser.y
diff -u ZendEngine2/zend_language_parser.y:1.186 
ZendEngine2/zend_language_parser.y:1.187
--- ZendEngine2/zend_language_parser.y:1.186Fri Jul 27 09:04:12 2007
+++ ZendEngine2/zend_language_parser.y  Thu Aug  2 21:53:53 2007
@@ -18,7 +18,7 @@
+--+
 */
 
-/* $Id: zend_language_parser.y,v 1.186 2007/07/27 09:04:12 dmitry Exp $ */
+/* $Id: zend_language_parser.y,v 1.187 2007/08/02 21:53:53 johannes Exp $ */
 
 /*
  * LALR shift/reduce conflicts and how they are resolved:
@@ -649,6 +649,12 @@
|   fully_qualified_class_name T_PAAMAYIM_NEKUDOTAYIM T_STRING '(' 
{ zend_do_begin_class_member_function_call($1, $3 TSRMLS_CC); }
function_call_parameter_list
')' { zend_do_end_function_call(NULL, $$, $6, 1, 1 
TSRMLS_CC); zend_do_extended_fcall_end(TSRMLS_C);}
+   |   variable_class_name T_PAAMAYIM_NEKUDOTAYIM T_STRING '(' { 
zend_do_begin_class_member_function_call($1, $3 TSRMLS_CC); }
+   function_call_parameter_list
+   ')' { zend_do_end_function_call(NULL, $$, $6, 1, 1 
TSRMLS_CC); zend_do_extended_fcall_end(TSRMLS_C);}
+   |   variable_class_name T_PAAMAYIM_NEKUDOTAYIM 
variable_without_objects '(' { zend_do_end_variable_parse(BP_VAR_R, 0 
TSRMLS_CC); zend_do_begin_class_member_function_call($1, $3 TSRMLS_CC); }
+   function_call_parameter_list
+   ')' { zend_do_end_function_call(NULL, $$, $6, 1, 1 
TSRMLS_CC); zend_do_extended_fcall_end(TSRMLS_C);}
|   fully_qualified_class_name T_PAAMAYIM_NEKUDOTAYIM 
variable_without_objects '(' { zend_do_end_variable_parse(BP_VAR_R, 0 
TSRMLS_CC); zend_do_begin_class_member_function_call($1, $3 TSRMLS_CC); }
function_call_parameter_list
')' { zend_do_end_function_call(NULL, $$, $6, 1, 1 
TSRMLS_CC); zend_do_extended_fcall_end(TSRMLS_C);}
@@ -809,6 +815,11 @@
 
 static_member:
fully_qualified_class_name T_PAAMAYIM_NEKUDOTAYIM 
variable_without_objects { $$ = $3; zend_do_fetch_static_member($$, $1 
TSRMLS_CC); }
+   |   variable_class_name T_PAAMAYIM_NEKUDOTAYIM 
variable_without_objects { $$ = $3; zend_do_fetch_static_member($$, $1 
TSRMLS_CC); }
+;
+
+variable_class_name:
+   reference_variable { zend_do_end_variable_parse(BP_VAR_R, 0 TSRMLS_CC); 
$$=$1;}
 ;
 
 
@@ -935,6 +946,7 @@
 
 class_constant:
fully_qualified_class_name T_PAAMAYIM_NEKUDOTAYIM T_STRING { 
zend_do_fetch_constant($$, $1, $3, ZEND_RT TSRMLS_CC); }
+   |   variable_class_name T_PAAMAYIM_NEKUDOTAYIM T_STRING { 
zend_do_fetch_constant($$, $1, $3, ZEND_RT TSRMLS_CC); }
 ;
 
 %%

http://cvs.php.net/viewvc.cgi/php-src/tests/lang/041.phpt?view=markuprev=1.1
Index: php-src/tests/lang/041.phpt
+++ php-src/tests/lang/041.phpt
--TEST--
Dynamic access of static members
--FILE--
?php
class A {
publicstatic $b = 'foo';
}

$classname   =  'A';
$binaryClassname = b'A';
$wrongClassname  =  'B';

echo $classname::$b.\n;
echo $binaryClassname::$b.\n;
echo $wrongClassname::$b.\n;

? 
===DONE===
--EXPECTF--
foo
foo

Fatal error: Class 'B' not found in %s041.php on line %d

http://cvs.php.net/viewvc.cgi/php-src/tests/lang/042.phpt?view=markuprev=1.1
Index: php-src/tests/lang/042.phpt
+++ php-src/tests/lang/042.phpt
--TEST--
Dynamic access of constants
--FILE--
?php
class A {
const B = 'foo';
}

$classname   =  'A';
$binaryClassname = b'A';
$wrongClassname  =  'B';

echo $classname::B.\n;
echo $binaryClassname::B.\n;
echo $wrongClassname::B.\n;
? 
===DONE===
--EXPECTF--
foo
foo

Fatal error: Class 'B' not found in %s042.php on line %d

http://cvs.php.net/viewvc.cgi/php-src/tests/lang/043.phpt?view=markuprev=1.1
Index: php-src/tests/lang/043.phpt
+++ php-src/tests/lang/043.phpt
--TEST--
Dynamic call for static methods
--FILE--
?php
class A {
static function foo() { return 'foo'; }
}

$classname   =  'A';
$binaryClassname = b'A';
$wrongClassname  =  'B';

echo $classname::foo().\n;
echo $binaryClassname::foo().\n;
echo $wrongClassname::foo().\n;
? 
===DONE===
--EXPECTF--
foo
foo

Fatal error: Class 'B' not found in %s043.php on line %d

http://cvs.php.net/viewvc.cgi/php-src/tests/lang/044.phpt?view=markuprev=1.1
Index: php-src/tests/lang/044.phpt
+++ php-src/tests/lang/044.phpt
--TEST--
Dynamic call for static methods dynamically named
--FILE--
?php
class A {
static function foo() { return 'foo'; }
}
$classname   

[PHP-CVS] cvs: php-src /ext/standard array.c

2007-08-08 Thread Johannes Schl
johannesWed Aug  8 14:52:41 2007 UTC

  Modified files:  
/php-src/ext/standard   array.c 
  Log:
  - Fix build (patch by Ulf Wendel)
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/array.c?r1=1.412r2=1.413diff_format=u
Index: php-src/ext/standard/array.c
diff -u php-src/ext/standard/array.c:1.412 php-src/ext/standard/array.c:1.413
--- php-src/ext/standard/array.c:1.412  Wed Aug  8 07:46:00 2007
+++ php-src/ext/standard/array.cWed Aug  8 14:52:40 2007
@@ -21,7 +21,7 @@
+--+
 */
 
-/* $Id: array.c,v 1.412 2007/08/08 07:46:00 jani Exp $ */
+/* $Id: array.c,v 1.413 2007/08/08 14:52:40 johannes Exp $ */
 
 #include php.h
 #include php_ini.h
@@ -1277,19 +1277,19 @@

if (var_name_type == IS_STRING) {
/* These are allowed as first char: [a-zA-Z_\x7f-\xff] */
-   if (var_name[0] == '_' ||
-   (((int)((unsigned char *)var_name)[0]) = 65  /* A
*/  /* Z*/ 90  = ((int)((unsigned char *)var_name)[0])) ||
-   (((int)((unsigned char *)var_name)[0]) = 97  /* a
*/  /* z*/ 122 = ((int)((unsigned char *)var_name)[0])) ||
-   (((int)((unsigned char *)var_name)[0]) = 127 /* 0x7f 
*/  /* 0xff */ 255 = ((int)((unsigned char *)var_name)[0]))   
+   if (((unsigned char *)var_name.s)[0] == '_' ||
+   (((int)((unsigned char *)var_name.s)[0]) = 65  /* A
*/  /* Z*/ 90  = ((int)((unsigned char *)var_name.s)[0])) ||
+   (((int)((unsigned char *)var_name.s)[0]) = 97  /* a
*/  /* z*/ 122 = ((int)((unsigned char *)var_name.s)[0])) ||
+   (((int)((unsigned char *)var_name.s)[0]) = 127 /* 0x7f 
*/  /* 0xff */ 255 = ((int)((unsigned char *)var_name.s)[0]))
) {
/* And these as the rest: [a-zA-Z0-9_\x7f-\xff] */
-   if (len  1) {
-   for (i = 1; i  len; i++) {
-   if (var_name[i] == '_' ||
-   (((int)((unsigned char 
*)var_name)[i]) = 48  /* 0*/  /* 9*/ 57  = ((int)((unsigned char 
*)var_name)[i])) ||
-   (((int)((unsigned char 
*)var_name)[i]) = 65  /* A*/  /* Z*/ 90  = ((int)((unsigned char 
*)var_name)[i])) ||
-   (((int)((unsigned char 
*)var_name)[i]) = 97  /* a*/  /* z*/ 122 = ((int)((unsigned char 
*)var_name)[i])) ||
-   (((int)((unsigned char 
*)var_name)[i]) = 127 /* 0x7f */  /* 0xff */ 255 = ((int)((unsigned char 
*)var_name)[i]))   
+   if (var_name_len  1) {
+   for (i = 1; i  var_name_len; i++) {
+   if (((unsigned char*)var_name.s)[i] == 
'_' ||
+   (((int)((unsigned char 
*)var_name.s)[i]) = 48  /* 0*/  /* 9*/ 57  = ((int)((unsigned 
char*)var_name.s)[i])) ||
+   (((int)((unsigned char 
*)var_name.s)[i]) = 65  /* A*/  /* Z*/ 90  = ((int)((unsigned 
char*)var_name.s)[i])) ||
+   (((int)((unsigned char 
*)var_name.s)[i]) = 97  /* a*/  /* z*/ 122 = ((int)((unsigned 
char*)var_name.s)[i])) ||
+   (((int)((unsigned char 
*)var_name.s)[i]) = 127 /* 0x7f */  /* 0xff */ 255 = ((int)((unsigned 
char*)var_name.s)[i]))
) { } else {
return 0;
}

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



[PHP-CVS] cvs: php-src /ext/tokenizer tokenizer_data_gen.sh

2007-08-09 Thread Johannes Schl
johannesThu Aug  9 22:24:42 2007 UTC

  Modified files:  
/php-src/ext/tokenizer  tokenizer_data_gen.sh 
  Log:
  - Write to the correct file...
  
http://cvs.php.net/viewvc.cgi/php-src/ext/tokenizer/tokenizer_data_gen.sh?r1=1.1r2=1.2diff_format=u
Index: php-src/ext/tokenizer/tokenizer_data_gen.sh
diff -u php-src/ext/tokenizer/tokenizer_data_gen.sh:1.1 
php-src/ext/tokenizer/tokenizer_data_gen.sh:1.2
--- php-src/ext/tokenizer/tokenizer_data_gen.sh:1.1 Tue Jul 31 23:23:37 2007
+++ php-src/ext/tokenizer/tokenizer_data_gen.sh Thu Aug  9 22:24:41 2007
@@ -1,7 +1,7 @@
 #!/bin/sh
 
 INFILE=../../Zend/zend_language_parser.c
-OUTFILE=tokenizer_data.h
+OUTFILE=tokenizer_data.c
 AWK=awk
 
 
@@ -30,7 +30,7 @@
+--+
 */
 
-/* $Id: tokenizer_data_gen.sh,v 1.1 2007/07/31 23:23:37 johannes Exp $ */
+/* $Id: tokenizer_data_gen.sh,v 1.2 2007/08/09 22:24:41 johannes Exp $ */
 
 /*
DO NOT EDIT THIS FILE!

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



[PHP-CVS] cvs: php-src /ext/spl spl_directory.c /ext/spl/tests bug42364.phpt

2007-08-21 Thread Johannes Schl
johannesTue Aug 21 22:43:38 2007 UTC

  Added files: 
/php-src/ext/spl/tests  bug42364.phpt 

  Modified files:  
/php-src/ext/splspl_directory.c 
  Log:
  - Fixed Bug #42364 Crash when using getRealPath with DirectoryIterator
  
http://cvs.php.net/viewvc.cgi/php-src/ext/spl/spl_directory.c?r1=1.134r2=1.135diff_format=u
Index: php-src/ext/spl/spl_directory.c
diff -u php-src/ext/spl/spl_directory.c:1.134 
php-src/ext/spl/spl_directory.c:1.135
--- php-src/ext/spl/spl_directory.c:1.134   Tue Jun  5 13:51:29 2007
+++ php-src/ext/spl/spl_directory.c Tue Aug 21 22:43:38 2007
@@ -16,7 +16,7 @@
+--+
  */
 
-/* $Id: spl_directory.c,v 1.134 2007/06/05 13:51:29 tony2001 Exp $ */
+/* $Id: spl_directory.c,v 1.135 2007/08/21 22:43:38 johannes Exp $ */
 
 #ifdef HAVE_CONFIG_H
 # include config.h
@@ -1020,13 +1020,17 @@
 
php_set_error_handling(EH_THROW, spl_ce_RuntimeException TSRMLS_CC);
 
+   if (intern-type == SPL_FS_DIR  !intern-file_name.v  
intern-u.dir.entry.d_name[0]) {
+   spl_filesystem_object_get_file_name(intern TSRMLS_CC);
+   }
+
if (intern-file_name_type == IS_UNICODE) {
php_stream_path_encode(NULL, filename, filename_len, 
intern-file_name.u, intern-file_name_len, REPORT_ERRORS, FG(default_context));
} else {
filename = intern-file_name.s;
}
 
-   if (VCWD_REALPATH(filename, buff)) {
+   if (filename  VCWD_REALPATH(filename, buff)) {
 #ifdef ZTS
if (VCWD_ACCESS(buff, F_OK)) {
RETVAL_FALSE;
@@ -1044,6 +1048,11 @@
} else {
RETVAL_FALSE;
}
+
+   if (intern-file_name_type == IS_UNICODE  filename) {
+   efree(filename);
+   }
+
php_set_error_handling(EH_NORMAL, NULL TSRMLS_CC);
 }
 /* }}} */

http://cvs.php.net/viewvc.cgi/php-src/ext/spl/tests/bug42364.phpt?view=markuprev=1.1
Index: php-src/ext/spl/tests/bug42364.phpt
+++ php-src/ext/spl/tests/bug42364.phpt
--TEST--
Bug #42364 (Crash when using getRealPath with DirectoryIterator)
--SKIPIF--
?php if (!extension_loaded(spl)) print skip; ?
--FILE--
?php
$it = new DirectoryIterator(dirname(__FILE__));

$count = 0;

foreach ($it as $e) {
$count++;
$type = gettype($e-getRealPath());
if ($type != string  $type != unicode) {
echo $e-getFilename(),  is a , gettype($e-getRealPath()), \n;
}
}

if ($count  0) {
echo Found $count entries!\n;
}
echo ===DONE===
?
--EXPECTF--
Found %i entries!
===DONE===

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



[PHP-CVS] cvs: php-src(PHP_5_3) / README.namespaces /ext/tokenizer tokenizer_data.c

2007-09-28 Thread Johannes Schl
johannesFri Sep 28 21:02:19 2007 UTC

  Added files: (Branch: PHP_5_3)
/php-srcREADME.namespaces 

  Modified files:  
/php-src/ext/tokenizer  tokenizer_data.c 
  Log:
  - Merge minor namespace related stuff (README and tokenizer)
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/tokenizer/tokenizer_data.c?r1=1.1.2.2r2=1.1.2.2.2.1diff_format=u
Index: php-src/ext/tokenizer/tokenizer_data.c
diff -u php-src/ext/tokenizer/tokenizer_data.c:1.1.2.2 
php-src/ext/tokenizer/tokenizer_data.c:1.1.2.2.2.1
--- php-src/ext/tokenizer/tokenizer_data.c:1.1.2.2  Tue Jul 31 23:24:11 2007
+++ php-src/ext/tokenizer/tokenizer_data.c  Fri Sep 28 21:02:19 2007
@@ -16,7 +16,7 @@
+--+
 */
 
-/* $Id: tokenizer_data.c,v 1.1.2.2 2007/07/31 23:24:11 johannes Exp $ */
+/* $Id: tokenizer_data.c,v 1.1.2.2.2.1 2007/09/28 21:02:19 johannes Exp $ */
 
 /*
DO NOT EDIT THIS FILE!
@@ -147,6 +147,9 @@
REGISTER_LONG_CONSTANT(T_DOLLAR_OPEN_CURLY_BRACES, 
T_DOLLAR_OPEN_CURLY_BRACES, CONST_CS | CONST_PERSISTENT);
REGISTER_LONG_CONSTANT(T_CURLY_OPEN, T_CURLY_OPEN, CONST_CS | 
CONST_PERSISTENT);
REGISTER_LONG_CONSTANT(T_PAAMAYIM_NEKUDOTAYIM, 
T_PAAMAYIM_NEKUDOTAYIM, CONST_CS | CONST_PERSISTENT);
+   REGISTER_LONG_CONSTANT(T_NAMESPACE, T_NAMESPACE, CONST_CS | 
CONST_PERSISTENT);
+   REGISTER_LONG_CONSTANT(T_IMPORT, T_IMPORT, CONST_CS | 
CONST_PERSISTENT);
+   REGISTER_LONG_CONSTANT(T_NS_C, T_NS_C, CONST_CS | CONST_PERSISTENT);
REGISTER_LONG_CONSTANT(T_DOUBLE_COLON, T_PAAMAYIM_NEKUDOTAYIM, 
CONST_CS | CONST_PERSISTENT);
 }
 
@@ -272,6 +275,9 @@
case T_DOLLAR_OPEN_CURLY_BRACES: return 
T_DOLLAR_OPEN_CURLY_BRACES;
case T_CURLY_OPEN: return T_CURLY_OPEN;
case T_PAAMAYIM_NEKUDOTAYIM: return T_DOUBLE_COLON;
+   case T_NAMESPACE: return T_NAMESPACE;
+   case T_IMPORT: return T_IMPORT;
+   case T_NS_C: return T_NS_C;
 
}
return UNKNOWN;

http://cvs.php.net/viewvc.cgi/php-src/README.namespaces?view=markuprev=1.1
Index: php-src/README.namespaces
+++ php-src/README.namespaces
Main assumption of the model is that the problem that we are to solve is the
problem of the very long class names in PHP libraries. We would not attempt
to take autoloader's job or create packaging model - only make names
manageable. 

Namespaces are defined the following way: 

Zend/DB/Connection.php: 
?php 
namespace Zend::DB;

class Connection {
}

function connect() {
}
?

Namespace definition does the following: 
All class and function names inside are automatically prefixed with
namespace name. Inside namespace, local name always takes precedence over
global name. It is possible to use the same namespace in several PHP files.
The namespace declaration statement must be the very first statement in
file.

Every class and function from namespace can be referred to by the full name
- e.g. Zend::DB::Connection or Zend::DB::connect - at any time. 

?php
require 'Zend/Db/Connection.php';
$x = new Zend::DB::Connection;
Zend::DB::connect();
?

Namespace or class name can be imported: 

?php 
require 'Zend/Db/Connection.php';
import Zend::DB;
import Zend::DB::Connection as DbConnection;
$x = new Zend::DB::Connection();
$y = new DB::connection();
$z = new DbConnection();
DB::connect();
?

import statement only defines name aliasing. It may create name alias for
namespace or class. The simple form of statement import A::B::C::D; is
equivalent to import A::B::C::D as D;. Import statement can be used at any
time in global scope (not inside function/class) and takes effect from the
point of definition down to the end of file. It is recommended however to
place imports at the beginning of the file. Import statements have effect
only on file where they are written.

The special empty namespace (:: prefix) is useful as explicit global
namespace qualification. All class and function names started from ::
interpreted as global. ?php namespace A::B::C;

$con = ::mysql_connect(...);
?

A special constant __NAMESPACE__ indicates the current namespace. It can be
used to construct fully-qualified names to pass them as callbacks.

?php
namespace A::B::C;

function foo() {
}

set_error_handler(__NAMESPACE__ . ::foo);
?

In global namespace __NAMESPACE__ constant has value of empty string.

Names inside namespace are resolved according to the following rules.

1) all qualified names are translated during compilation according to
current import rules. So if we have import A::B::C; and then C::D::e();
it is translated to A::B::C::D::e()
2) unqualified class names translated during compilation according to
current import rules. So if we have import A::B::C; and then new C(); it
is translated to new A::B::C()

3) calls to unqualified functions that are defined in current namespace
interpreted as calls to corresponding functions
4) 

[PHP-CVS] cvs: php-src / README.PARAMETER_PARSING_API

2007-09-28 Thread Johannes Schl
johannesFri Sep 28 22:04:28 2007 UTC

  Modified files:  
/php-srcREADME.PARAMETER_PARSING_API 
  Log:
  - Fix type in example
  
http://cvs.php.net/viewvc.cgi/php-src/README.PARAMETER_PARSING_API?r1=1.21r2=1.22diff_format=u
Index: php-src/README.PARAMETER_PARSING_API
diff -u php-src/README.PARAMETER_PARSING_API:1.21 
php-src/README.PARAMETER_PARSING_API:1.22
--- php-src/README.PARAMETER_PARSING_API:1.21   Wed May 23 18:48:16 2007
+++ php-src/README.PARAMETER_PARSING_APIFri Sep 28 22:04:28 2007
@@ -93,7 +93,7 @@
 /* Gets an object of class specified by my_ce, and an optional double. */
 zval *obj;
 double d = 0.5;
-zend_class_entry my_ce;
+zend_class_entry *my_ce;
 if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, O|d,
   obj, my_ce, d) == FAILURE) {
 return;

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



[PHP-CVS] cvs: php-src(PHP_5_3) / README.PARAMETER_PARSING_API

2007-09-28 Thread Johannes Schl
johannesFri Sep 28 22:04:40 2007 UTC

  Modified files:  (Branch: PHP_5_3)
/php-srcREADME.PARAMETER_PARSING_API 
  Log:
  - MFH: Fix type in example
  
http://cvs.php.net/viewvc.cgi/php-src/README.PARAMETER_PARSING_API?r1=1.7.6.2r2=1.7.6.2.2.1diff_format=u
Index: php-src/README.PARAMETER_PARSING_API
diff -u php-src/README.PARAMETER_PARSING_API:1.7.6.2 
php-src/README.PARAMETER_PARSING_API:1.7.6.2.2.1
--- php-src/README.PARAMETER_PARSING_API:1.7.6.2Mon Feb  5 17:57:51 2007
+++ php-src/README.PARAMETER_PARSING_APIFri Sep 28 22:04:39 2007
@@ -70,7 +70,7 @@
 /* Gets an object of class specified by my_ce, and an optional double. */
 zval *obj;
 double d = 0.5;
-zend_class_entry my_ce;
+zend_class_entry *my_ce;
 if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, O|d,
  obj, my_ce, d) == FAILURE) {
return;

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



[PHP-CVS] cvs: php-src(PHP_5_2) / README.PARAMETER_PARSING_API

2007-09-28 Thread Johannes Schl
johannesFri Sep 28 22:04:47 2007 UTC

  Modified files:  (Branch: PHP_5_2)
/php-srcREADME.PARAMETER_PARSING_API 
  Log:
  - MFH: Fix type in example
  
http://cvs.php.net/viewvc.cgi/php-src/README.PARAMETER_PARSING_API?r1=1.7.6.2r2=1.7.6.3diff_format=u
Index: php-src/README.PARAMETER_PARSING_API
diff -u php-src/README.PARAMETER_PARSING_API:1.7.6.2 
php-src/README.PARAMETER_PARSING_API:1.7.6.3
--- php-src/README.PARAMETER_PARSING_API:1.7.6.2Mon Feb  5 17:57:51 2007
+++ php-src/README.PARAMETER_PARSING_APIFri Sep 28 22:04:47 2007
@@ -70,7 +70,7 @@
 /* Gets an object of class specified by my_ce, and an optional double. */
 zval *obj;
 double d = 0.5;
-zend_class_entry my_ce;
+zend_class_entry *my_ce;
 if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, O|d,
  obj, my_ce, d) == FAILURE) {
return;

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



[PHP-CVS] cvs: php-src(PHP_5_3) /ext/standard/tests/general_functions error_get_last.phpt

2007-10-01 Thread Johannes Schl
johannesMon Oct  1 15:01:47 2007 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/standard/tests/general_functions   error_get_last.phpt 
  Log:
  - Fix test
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/general_functions/error_get_last.phpt?r1=1.1.2.2.2.1r2=1.1.2.2.2.2diff_format=u
Index: php-src/ext/standard/tests/general_functions/error_get_last.phpt
diff -u 
php-src/ext/standard/tests/general_functions/error_get_last.phpt:1.1.2.2.2.1 
php-src/ext/standard/tests/general_functions/error_get_last.phpt:1.1.2.2.2.2
--- 
php-src/ext/standard/tests/general_functions/error_get_last.phpt:1.1.2.2.2.1
Mon Oct  1 12:40:54 2007
+++ php-src/ext/standard/tests/general_functions/error_get_last.phptMon Oct 
 1 15:01:47 2007
@@ -24,7 +24,7 @@
   [message]=
   string(54) error_get_last() expects exactly 0 parameters, 1 given
   [file]=
-  string(78) %s
+  string(%i) %s
   [line]=
   int(4)
 }
@@ -36,7 +36,7 @@
   [message]=
   string(21) Undefined variable: b
   [file]=
-  string(78) %s
+  string(%i) %s
   [line]=
   int(7)
 }

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



[PHP-CVS] cvs: php-src(PHP_5_3) /ext/standard basic_functions.c

2007-10-01 Thread Johannes Schl
johannesMon Oct  1 20:36:01 2007 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/standard   basic_functions.c 
  Log:
  - pass the adress not the value
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/basic_functions.c?r1=1.725.2.31.2.64.2.4r2=1.725.2.31.2.64.2.5diff_format=u
Index: php-src/ext/standard/basic_functions.c
diff -u php-src/ext/standard/basic_functions.c:1.725.2.31.2.64.2.4 
php-src/ext/standard/basic_functions.c:1.725.2.31.2.64.2.5
--- php-src/ext/standard/basic_functions.c:1.725.2.31.2.64.2.4  Mon Oct  1 
12:40:53 2007
+++ php-src/ext/standard/basic_functions.c  Mon Oct  1 20:36:01 2007
@@ -17,7 +17,7 @@
+--+
  */
 
-/* $Id: basic_functions.c,v 1.725.2.31.2.64.2.4 2007/10/01 12:40:53 jani Exp $ 
*/
+/* $Id: basic_functions.c,v 1.725.2.31.2.64.2.5 2007/10/01 20:36:01 johannes 
Exp $ */
 
 #include php.h
 #include php_streams.h
@@ -6125,7 +6125,7 @@
RETURN_FALSE;
}
 
-   if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, ss, path, 
path_len, new_path, new_path_len) == FAILURE) {
+   if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, ss, path, 
path_len, new_path, new_path_len) == FAILURE) {
return;
}
 

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



[PHP-CVS] cvs: php-src /ext/mysqli mysqli.c

2006-03-05 Thread Johannes Schl
johannesSun Mar  5 15:49:55 2006 UTC

  Modified files:  
/php-src/ext/mysqli mysqli.c 
  Log:
  - Fix build after unicode changes
  
http://cvs.php.net/viewcvs.cgi/php-src/ext/mysqli/mysqli.c?r1=1.80r2=1.81diff_format=u
Index: php-src/ext/mysqli/mysqli.c
diff -u php-src/ext/mysqli/mysqli.c:1.80 php-src/ext/mysqli/mysqli.c:1.81
--- php-src/ext/mysqli/mysqli.c:1.80Wed Mar  1 18:37:25 2006
+++ php-src/ext/mysqli/mysqli.c Sun Mar  5 15:49:55 2006
@@ -15,7 +15,7 @@
   | Author: Georg Richter [EMAIL PROTECTED]|
   +--+
 
-  $Id: mysqli.c,v 1.80 2006/03/01 18:37:25 iliaa Exp $ 
+  $Id: mysqli.c,v 1.81 2006/03/05 15:49:55 johannes Exp $ 
 */
 
 #ifdef HAVE_CONFIG_H
@@ -215,7 +215,7 @@
if (ret == SUCCESS) {
 
/* check if mysqli object is still valid */
-   if (!strcmp(obj-zo.ce-name, mysqli)) {
+   if (!strcmp(obj-zo.ce-name.s, mysqli)) {
if (!obj-ptr ||
!((MYSQL *)((MY_MYSQL *)((MYSQLI_RESOURCE 
*)(obj-ptr))-ptr)-mysql)-thread_id) {
retval = EG(uninitialized_zval_ptr);
@@ -223,7 +223,7 @@
}
} else
/* check if stmt object is still valid */
-   if (!strcmp(obj-zo.ce-name, mysqli_stmt)) {
+   if (!strcmp(obj-zo.ce-name.s, mysqli_stmt)) {
if (!obj-ptr ||
!((MYSQL_STMT *)((MY_STMT *)((MYSQLI_RESOURCE 
*)(obj-ptr))-ptr)-stmt)-mysql) {
retval = EG(uninitialized_zval_ptr);
@@ -356,7 +356,7 @@
{
mysqli_base_class = mysqli_base_class-parent;
}
-   zend_hash_find(classes, mysqli_base_class-name, 
mysqli_base_class-name_length + 1, 
+   zend_hash_find(classes, mysqli_base_class-name.s, 
mysqli_base_class-name_length + 1, 
(void **) intern-prop_handler);
 
ALLOC_HASHTABLE(intern-zo.properties);
@@ -460,33 +460,33 @@
ce = mysqli_driver_class_entry;
zend_hash_init(mysqli_driver_properties, 0, NULL, NULL, 1);
MYSQLI_ADD_PROPERTIES(mysqli_driver_properties, 
mysqli_driver_property_entries);
-   zend_hash_add(classes, ce-name, ce-name_length+1, 
mysqli_driver_properties, sizeof(mysqli_driver_properties), NULL);
+   zend_hash_add(classes, ce-name.s, ce-name_length+1, 
mysqli_driver_properties, sizeof(mysqli_driver_properties), NULL);
 ce-ce_flags |= ZEND_ACC_FINAL_CLASS;
 
REGISTER_MYSQLI_CLASS_ENTRY(mysqli, mysqli_link_class_entry, 
mysqli_link_methods);
ce = mysqli_link_class_entry;
zend_hash_init(mysqli_link_properties, 0, NULL, NULL, 1);
MYSQLI_ADD_PROPERTIES(mysqli_link_properties, 
mysqli_link_property_entries);
-   zend_hash_add(classes, ce-name, ce-name_length+1, 
mysqli_link_properties, sizeof(mysqli_link_properties), NULL);
+   zend_hash_add(classes, ce-name.s, ce-name_length+1, 
mysqli_link_properties, sizeof(mysqli_link_properties), NULL);
 
REGISTER_MYSQLI_CLASS_ENTRY(mysqli_warning, 
mysqli_warning_class_entry, mysqli_warning_methods);
ce = mysqli_warning_class_entry;
 ce-ce_flags |= ZEND_ACC_FINAL_CLASS | ZEND_ACC_PROTECTED;
zend_hash_init(mysqli_warning_properties, 0, NULL, NULL, 1);
MYSQLI_ADD_PROPERTIES(mysqli_warning_properties, 
mysqli_warning_property_entries);
-   zend_hash_add(classes, ce-name, ce-name_length+1, 
mysqli_warning_properties, sizeof(mysqli_warning_properties), NULL);
+   zend_hash_add(classes, ce-name.s, ce-name_length+1, 
mysqli_warning_properties, sizeof(mysqli_warning_properties), NULL);
 
REGISTER_MYSQLI_CLASS_ENTRY(mysqli_result, mysqli_result_class_entry, 
mysqli_result_methods);
ce = mysqli_result_class_entry;
zend_hash_init(mysqli_result_properties, 0, NULL, NULL, 1);
MYSQLI_ADD_PROPERTIES(mysqli_result_properties, 
mysqli_result_property_entries);
-   zend_hash_add(classes, ce-name, ce-name_length+1, 
mysqli_result_properties, sizeof(mysqli_result_properties), NULL);
+   zend_hash_add(classes, ce-name.s, ce-name_length+1, 
mysqli_result_properties, sizeof(mysqli_result_properties), NULL);
 
REGISTER_MYSQLI_CLASS_ENTRY(mysqli_stmt, mysqli_stmt_class_entry, 
mysqli_stmt_methods);
ce = mysqli_stmt_class_entry;
zend_hash_init(mysqli_stmt_properties, 0, NULL, NULL, 1);
MYSQLI_ADD_PROPERTIES(mysqli_stmt_properties, 
mysqli_stmt_property_entries);
-   zend_hash_add(classes, ce-name, ce-name_length+1, 
mysqli_stmt_properties, sizeof(mysqli_stmt_properties), NULL);
+   zend_hash_add(classes, ce-name.s, ce-name_length+1, 
mysqli_stmt_properties, sizeof(mysqli_stmt_properties), NULL);

/* mysqli_options */
REGISTER_LONG_CONSTANT(MYSQLI_READ_DEFAULT_GROUP, 

[PHP-CVS] cvs: php-src /ext/standard array.c

2006-04-12 Thread Johannes Schl
johannesWed Apr 12 19:29:52 2006 UTC

  Modified files:  
/php-src/ext/standard   array.c 
  Log:
  - Fix bug #37060 (Type of retval of Countable::count() is not checked)
  
http://cvs.php.net/viewcvs.cgi/php-src/ext/standard/array.c?r1=1.347r2=1.348diff_format=u
Index: php-src/ext/standard/array.c
diff -u php-src/ext/standard/array.c:1.347 php-src/ext/standard/array.c:1.348
--- php-src/ext/standard/array.c:1.347  Sun Mar 26 11:06:24 2006
+++ php-src/ext/standard/array.cWed Apr 12 19:29:52 2006
@@ -21,7 +21,7 @@
+--+
 */
 
-/* $Id: array.c,v 1.347 2006/03/26 11:06:24 derick Exp $ */
+/* $Id: array.c,v 1.348 2006/04/12 19:29:52 johannes Exp $ */
 
 #include php.h
 #include php_ini.h
@@ -314,6 +314,7 @@
if (Z_OBJ_HT_P(array)-get_class_entry  
instanceof_function(Z_OBJCE_P(array), spl_ce_Countable TSRMLS_CC)) {
zend_call_method_with_0_params(array, NULL, 
NULL, count, retval);
if (retval) {
+   convert_to_long(retval);
RETVAL_LONG(Z_LVAL_P(retval));
zval_ptr_dtor(retval);
}

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



[PHP-CVS] cvs: php-src(PHP_5_1) / NEWS /ext/standard array.c

2006-04-12 Thread Johannes Schl
johannesWed Apr 12 19:30:52 2006 UTC

  Modified files:  (Branch: PHP_5_1)
/php-srcNEWS 
/php-src/ext/standard   array.c 
  Log:
  - MFH: Fix bug #37060 (Type of retval of Countable::count() is not checked)
  
http://cvs.php.net/viewcvs.cgi/php-src/NEWS?r1=1.2027.2.510r2=1.2027.2.511diff_format=u
Index: php-src/NEWS
diff -u php-src/NEWS:1.2027.2.510 php-src/NEWS:1.2027.2.511
--- php-src/NEWS:1.2027.2.510   Wed Apr 12 19:21:34 2006
+++ php-src/NEWSWed Apr 12 19:30:52 2006
@@ -1,6 +1,8 @@
 PHPNEWS
 |||
 ?? Apr 2006, PHP 5.1.3
+- Fixed bug #37060 (Type of retval of Countable::count() is not checked). 
+  (Johannes)
 - FIxed bug #37059 (oci_bind_by_name() doesn't support RAW and LONG RAW 
   fields). (Tony)
 - Fixed bug #37057 (xmlrpc_decode() may produce arrays with numeric strings, 
http://cvs.php.net/viewcvs.cgi/php-src/ext/standard/array.c?r1=1.308.2.20r2=1.308.2.21diff_format=u
Index: php-src/ext/standard/array.c
diff -u php-src/ext/standard/array.c:1.308.2.20 
php-src/ext/standard/array.c:1.308.2.21
--- php-src/ext/standard/array.c:1.308.2.20 Wed Mar 22 22:05:51 2006
+++ php-src/ext/standard/array.cWed Apr 12 19:30:52 2006
@@ -21,7 +21,7 @@
+--+
 */
 
-/* $Id: array.c,v 1.308.2.20 2006/03/22 22:05:51 tony2001 Exp $ */
+/* $Id: array.c,v 1.308.2.21 2006/04/12 19:30:52 johannes Exp $ */
 
 #include php.h
 #include php_ini.h
@@ -313,6 +313,7 @@
if (Z_OBJ_HT_P(array)-get_class_entry  
instanceof_function(Z_OBJCE_P(array), spl_ce_Countable TSRMLS_CC)) {
zend_call_method_with_0_params(array, NULL, 
NULL, count, retval);
if (retval) {
+   convert_to_long(retval);
RETVAL_LONG(Z_LVAL_P(retval));
zval_ptr_dtor(retval);
}

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



[PHP-CVS] cvs: php-src /main main.c

2006-05-27 Thread Johannes Schl
johannesSat May 27 20:53:38 2006 UTC

  Modified files:  
/php-src/main   main.c 
  Log:
  - nitpicking PHP6 vs. PHP 6
  
http://cvs.php.net/viewcvs.cgi/php-src/main/main.c?r1=1.691r2=1.692diff_format=u
Index: php-src/main/main.c
diff -u php-src/main/main.c:1.691 php-src/main/main.c:1.692
--- php-src/main/main.c:1.691   Wed May 24 22:00:57 2006
+++ php-src/main/main.c Sat May 27 20:53:38 2006
@@ -18,7 +18,7 @@
+--+
 */
 
-/* $Id: main.c,v 1.691 2006/05/24 22:00:57 edink Exp $ */
+/* $Id: main.c,v 1.692 2006/05/27 20:53:38 johannes Exp $ */
 
 /* {{{ includes
  */
@@ -1602,7 +1602,7 @@
 
while (*p) {
if (cfg_get_long((char*)*p, val) == SUCCESS  val) {
-   zend_error(E_CORE_ERROR, Directive '%s' is no 
longer supported in PHP6 and greater, *p);
+   zend_error(E_CORE_ERROR, Directive '%s' is no 
longer supported in PHP 6 and greater, *p);
}
++p;
}

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



[PHP-CVS] cvs: php-src /sapi/cgi cgi_main.c /sapi/cli php_cli.c

2006-06-03 Thread Johannes Schl
johannesSat Jun  3 22:00:31 2006 UTC

  Modified files:  
/php-src/sapi/cli   php_cli.c 
/php-src/sapi/cgi   cgi_main.c 
  Log:
  - Removed useless -g command line option from CGI and CLI
  - Fixed conflicting behaviour if -B and -a are set with CLI
  - Fixed handling of auto_prepend and exceptions in readline-a-mode
  
http://cvs.php.net/viewcvs.cgi/php-src/sapi/cli/php_cli.c?r1=1.155r2=1.156diff_format=u
Index: php-src/sapi/cli/php_cli.c
diff -u php-src/sapi/cli/php_cli.c:1.155 php-src/sapi/cli/php_cli.c:1.156
--- php-src/sapi/cli/php_cli.c:1.155Sat Jun  3 11:19:44 2006
+++ php-src/sapi/cli/php_cli.c  Sat Jun  3 22:00:30 2006
@@ -20,7 +20,7 @@
+--+
 */
 
-/* $Id: php_cli.c,v 1.155 2006/06/03 11:19:44 mike Exp $ */
+/* $Id: php_cli.c,v 1.156 2006/06/03 22:00:30 johannes Exp $ */
 
 #include php.h
 #include php_globals.h
@@ -130,7 +130,6 @@
{'e', 0, profile-info},
{'F', 1, process-file},
{'f', 1, file},
-   {'g', 1, global},
{'h', 0, help},
{'i', 0, info},
{'l', 0, syntax-check},
@@ -424,7 +423,7 @@
  -n   No php.ini file will be 
used\n
  -d foo[=bar] Define INI entry foo with 
value 'bar'\n
  -e   Generate extended 
information for debugger/profiler\n
- -f fileParse file.\n
+ -f fileParse and execute file.\n
  -h   This help\n
  -i   PHP information\n
  -l   Syntax check only (lint)\n
@@ -453,21 +452,6 @@
 }
 /* }}} */
 
-static void php_register_command_line_global_vars(char **arg TSRMLS_DC)
-{
-   char *var, *val;
-
-   var = *arg;
-   val = strchr(var, '=');
-   if (!val) {
-   printf(No value specified for variable '%s'\n, var);
-   } else {
-   *val++ = '\0';
-   php_register_variable(var, val, NULL TSRMLS_CC);
-   }
-   efree(*arg);
-}
-
 static php_stream *s_in_process = NULL;
 
 static void cli_register_file_handles(TSRMLS_D)
@@ -577,7 +561,6 @@
char *orig_optarg=php_optarg;
char *arg_free=NULL, **arg_excp=arg_free;
char *script_file=NULL;
-   zend_llist global_vars;
int interactive=0;
int module_started = 0;
int lineno = 0;
@@ -699,8 +682,6 @@
module_started = 1;
 
zend_first_try {
-   zend_llist_init(global_vars, sizeof(char *), NULL, 0);
-
CG(in_compilation) = 0; /* not initialized but needed for 
several options */
EG(uninitialized_zval_ptr) = NULL;
 
@@ -782,12 +763,11 @@
 
case 'a':   /* interactive mode */
if (!interactive) {
-#if (HAVE_LIBREADLINE || HAVE_LIBEDIT)  !defined(COMPILE_DL_READLINE)
-   printf(Interactive shell\n\n);
-#else
-   printf(Interactive mode enabled\n\n);
-#endif
-   fflush(stdout);
+   if (behavior != PHP_MODE_STANDARD) {
+   param_error = 
param_mode_conflict;
+   break;
+   }
+
interactive=1;
}
break;
@@ -825,14 +805,6 @@
script_file = php_optarg;
break;
 
-   case 'g': /* define global variables on command line */
-   {
-   char *arg = estrdup(php_optarg);
-
-   zend_llist_add_element(global_vars, 
arg);
-   }
-   break;
-
case 'l': /* syntax check mode */
if (behavior != PHP_MODE_STANDARD) {
break;
@@ -860,7 +832,7 @@
param_error = You can use -r 
only once.\n;
break;
}
-   } else if (behavior != PHP_MODE_STANDARD) {
+   } else if (behavior != PHP_MODE_STANDARD || 
interactive) {
param_error = param_mode_conflict;
break;
}
@@ -888,7 +860,7 @@
param_error = You can use -B 
only once.\n;
   

[PHP-CVS] cvs: php-src(PHP_5_2) /sapi/cgi cgi_main.c /sapi/cli php_cli.c

2006-06-03 Thread Johannes Schl
johannesSat Jun  3 22:02:02 2006 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/sapi/cli   php_cli.c 
/php-src/sapi/cgi   cgi_main.c 
  Log:
  MFH
  http://cvs.php.net/viewcvs.cgi/php-src/sapi/cli/php_cli.c?r1=1.129.2.13.2.2r2=1.129.2.13.2.3diff_format=u
Index: php-src/sapi/cli/php_cli.c
diff -u php-src/sapi/cli/php_cli.c:1.129.2.13.2.2 
php-src/sapi/cli/php_cli.c:1.129.2.13.2.3
--- php-src/sapi/cli/php_cli.c:1.129.2.13.2.2   Thu May 11 22:10:31 2006
+++ php-src/sapi/cli/php_cli.c  Sat Jun  3 22:02:02 2006
@@ -20,7 +20,7 @@
+--+
 */
 
-/* $Id: php_cli.c,v 1.129.2.13.2.2 2006/05/11 22:10:31 dmitry Exp $ */
+/* $Id: php_cli.c,v 1.129.2.13.2.3 2006/06/03 22:02:02 johannes Exp $ */
 
 #include php.h
 #include php_globals.h
@@ -122,7 +122,6 @@
{'e', 0, profile-info},
{'F', 1, process-file},
{'f', 1, file},
-   {'g', 1, global},
{'h', 0, help},
{'i', 0, info},
{'l', 0, syntax-check},
@@ -415,7 +414,7 @@
  -n   No php.ini file will be 
used\n
  -d foo[=bar] Define INI entry foo with 
value 'bar'\n
  -e   Generate extended 
information for debugger/profiler\n
- -f fileParse file.\n
+ -f fileParse and execute file.\n
  -h   This help\n
  -i   PHP information\n
  -l   Syntax check only (lint)\n
@@ -467,21 +466,6 @@
 }
 
 
-static void php_register_command_line_global_vars(char **arg TSRMLS_DC)
-{
-   char *var, *val;
-
-   var = *arg;
-   val = strchr(var, '=');
-   if (!val) {
-   printf(No value specified for variable '%s'\n, var);
-   } else {
-   *val++ = '\0';
-   php_register_variable(var, val, NULL TSRMLS_CC);
-   }
-   efree(*arg);
-}
-
 static php_stream *s_in_process = NULL;
 
 static void cli_register_file_handles(TSRMLS_D)
@@ -591,7 +575,6 @@
char *orig_optarg=php_optarg;
char *arg_free=NULL, **arg_excp=arg_free;
char *script_file=NULL;
-   zend_llist global_vars;
int interactive=0;
int module_started = 0;
int lineno = 0;
@@ -690,8 +673,6 @@
module_started = 1;
 
zend_first_try {
-   zend_llist_init(global_vars, sizeof(char *), NULL, 0);
-
zend_uv.html_errors = 0; /* tell the engine we're in non-html 
mode */
CG(in_compilation) = 0; /* not initialized but needed for 
several options */
EG(uninitialized_zval_ptr) = NULL;
@@ -786,12 +767,11 @@
 
case 'a':   /* interactive mode */
if (!interactive) {
-#if (HAVE_LIBREADLINE || HAVE_LIBEDIT)  !defined(COMPILE_DL_READLINE)
-   printf(Interactive shell\n\n);
-#else
-   printf(Interactive mode enabled\n\n);
-#endif
-   fflush(stdout);
+   if (behavior != PHP_MODE_STANDARD) {
+   param_error = 
param_mode_conflict;
+   break;
+   }
+
interactive=1;
}
break;
@@ -829,14 +809,6 @@
script_file = php_optarg;
break;
 
-   case 'g': /* define global variables on command line */
-   {
-   char *arg = estrdup(php_optarg);
-
-   zend_llist_add_element(global_vars, 
arg);
-   }
-   break;
-
case 'l': /* syntax check mode */
if (behavior != PHP_MODE_STANDARD) {
break;
@@ -864,7 +836,7 @@
param_error = You can use -r 
only once.\n;
break;
}
-   } else if (behavior != PHP_MODE_STANDARD) {
+   } else if (behavior != PHP_MODE_STANDARD || 
interactive) {
param_error = param_mode_conflict;
break;
}
@@ -892,7 +864,7 @@
param_error = You can use -B 
only once.\n;
   

[PHP-CVS] cvs: php-src /ext/reflection config.w32

2006-09-02 Thread Johannes Schl
johannesSat Sep  2 19:12:57 2006 UTC

  Modified files:  
/php-src/ext/reflection config.w32 
  Log:
  - Add HAVE_REFLECTION define for win32 (by Steph)
  
http://cvs.php.net/viewvc.cgi/php-src/ext/reflection/config.w32?r1=1.2r2=1.3diff_format=u
Index: php-src/ext/reflection/config.w32
diff -u php-src/ext/reflection/config.w32:1.2 
php-src/ext/reflection/config.w32:1.3
--- php-src/ext/reflection/config.w32:1.2   Thu Nov 17 22:49:03 2005
+++ php-src/ext/reflection/config.w32   Sat Sep  2 19:12:57 2006
@@ -1,9 +1,10 @@
-// $Id: config.w32,v 1.2 2005/11/17 22:49:03 helly Exp $
+// $Id: config.w32,v 1.3 2006/09/02 19:12:57 johannes Exp $
 // vim:ft=javascript
 
 ARG_ENABLE(reflection, disable reflection support, yes);
 
 if (PHP_REFLECTION != no) {
EXTENSION(reflection, php_reflection.c);
+   AC_DEFINE('HAVE_REFLECTION', 1, 'Reflection support enabled');
 }
 

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



[PHP-CVS] cvs: php-src(PHP_5_2) /ext/standard credits.c

2006-09-03 Thread Johannes Schl
johannesSun Sep  3 11:27:50 2006 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/ext/standard   credits.c 
  Log:
  - Remove version number here as already done in HEAD
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/credits.c?r1=1.36.2.4r2=1.36.2.4.2.1diff_format=u
Index: php-src/ext/standard/credits.c
diff -u php-src/ext/standard/credits.c:1.36.2.4 
php-src/ext/standard/credits.c:1.36.2.4.2.1
--- php-src/ext/standard/credits.c:1.36.2.4 Thu Mar 23 18:36:46 2006
+++ php-src/ext/standard/credits.c  Sun Sep  3 11:27:50 2006
@@ -17,7 +17,7 @@
+--+
 */
 
-/* $Id: credits.c,v 1.36.2.4 2006/03/23 18:36:46 iliaa Exp $ */
+/* $Id: credits.c,v 1.36.2.4.2.1 2006/09/03 11:27:50 johannes Exp $ */
 
 #include php.h
 #include info.h
@@ -105,7 +105,7 @@
 
if (flag  PHP_CREDITS_QA) {
php_info_print_table_start();
-   php_info_print_table_header(1, PHP 5.1 Quality Assurance 
Team);
+   php_info_print_table_header(1, PHP Quality Assurance Team);
php_info_print_table_row(1, Ilia Alshanetsky, Joerg Behrens, 
Antony Dovgal, Stefan Esser, Moriyoshi Koizumi, Magnus Maatta, Sebastian Nohn, 
Derick Rethans, Melvyn Sopacua, Jani Taskinen);
php_info_print_table_end();
}

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



[PHP-CVS] cvs: php-src /ext/reflection php_reflection.c

2006-09-11 Thread Johannes Schl
johannesMon Sep 11 17:06:59 2006 UTC

  Modified files:  
/php-src/ext/reflection php_reflection.c 
  Log:
  - Fix #37923 (Display constant value in reflection::export)
  
http://cvs.php.net/viewvc.cgi/php-src/ext/reflection/php_reflection.c?r1=1.252r2=1.253diff_format=u
Index: php-src/ext/reflection/php_reflection.c
diff -u php-src/ext/reflection/php_reflection.c:1.252 
php-src/ext/reflection/php_reflection.c:1.253
--- php-src/ext/reflection/php_reflection.c:1.252   Sun Sep 10 13:35:32 2006
+++ php-src/ext/reflection/php_reflection.c Mon Sep 11 17:06:59 2006
@@ -20,7 +20,7 @@
+--+
 */
 
-/* $Id: php_reflection.c,v 1.252 2006/09/10 13:35:32 bjori Exp $ */
+/* $Id: php_reflection.c,v 1.253 2006/09/11 17:06:59 johannes Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -530,10 +530,23 @@
 /* {{{ _const_string */
 static void _const_string(string *str, char *name, zval *value, char *indent 
TSRMLS_DC)
 {
-   string_printf(str, %sConstant [ %s %v ] { }\n,
+   zval value_copy;
+   int use_copy;
+
+   zend_make_printable_zval(value, value_copy, use_copy);
+   if (use_copy) {
+   value = value_copy;
+   }
+
+   string_printf(str, %sConstant [ %s %v ] { %s }\n,
   indent,
   zend_zval_type_name(value),
-  name);
+  name,
+  Z_STRVAL_P(value));
+
+   if (use_copy) {
+   zval_dtor(value);
+   }
 }
 /* }}} */
 
@@ -4867,7 +4880,7 @@
php_info_print_table_start();
php_info_print_table_header(2, Reflection, enabled);
 
-   php_info_print_table_row(2, Version, $Id: php_reflection.c,v 1.252 
2006/09/10 13:35:32 bjori Exp $);
+   php_info_print_table_row(2, Version, $Id: php_reflection.c,v 1.253 
2006/09/11 17:06:59 johannes Exp $);
 
php_info_print_table_end();
 } /* }}} */

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



[PHP-CVS] cvs: php-src(PHP_5_2) / NEWS /ext/reflection php_reflection.c

2006-09-11 Thread Johannes Schl
johannesMon Sep 11 17:08:43 2006 UTC

  Modified files:  (Branch: PHP_5_2)
/php-srcNEWS 
/php-src/ext/reflection php_reflection.c 
  Log:
  - MFH: Fix #37923 (Display constant value in reflection::export)
  
http://cvs.php.net/viewvc.cgi/php-src/NEWS?r1=1.2027.2.547.2.244r2=1.2027.2.547.2.245diff_format=u
Index: php-src/NEWS
diff -u php-src/NEWS:1.2027.2.547.2.244 php-src/NEWS:1.2027.2.547.2.245
--- php-src/NEWS:1.2027.2.547.2.244 Mon Sep 11 14:52:20 2006
+++ php-src/NEWSMon Sep 11 17:08:42 2006
@@ -16,6 +16,7 @@
   (php_lists at realplain dot com, Ilia)
 - Fixed bug #38096 (large timeout values ignored on 32bit machines in
   stream_socket_accept() and stream_socket_client()). (Ilia)
+- Fixed bug #37923 (Display constant value in reflection::export). (Johannes)
 
 31 Aug 2006, PHP 5.2.0RC3
 - Updated PCRE to version 6.7. (Ilia)
http://cvs.php.net/viewvc.cgi/php-src/ext/reflection/php_reflection.c?r1=1.164.2.33.2.22r2=1.164.2.33.2.23diff_format=u
Index: php-src/ext/reflection/php_reflection.c
diff -u php-src/ext/reflection/php_reflection.c:1.164.2.33.2.22 
php-src/ext/reflection/php_reflection.c:1.164.2.33.2.23
--- php-src/ext/reflection/php_reflection.c:1.164.2.33.2.22 Sun Sep 10 
13:25:47 2006
+++ php-src/ext/reflection/php_reflection.c Mon Sep 11 17:08:42 2006
@@ -20,7 +20,7 @@
+--+
 */
 
-/* $Id: php_reflection.c,v 1.164.2.33.2.22 2006/09/10 13:25:47 bjori Exp $ */
+/* $Id: php_reflection.c,v 1.164.2.33.2.23 2006/09/11 17:08:42 johannes Exp $ 
*/
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -537,10 +537,23 @@
 /* {{{ _const_string */
 static void _const_string(string *str, char *name, zval *value, char *indent 
TSRMLS_DC)
 {
-   string_printf(str, %sConstant [ %s %s ] { }\n,
+   zval value_copy;
+   int use_copy;
+
+   zend_make_printable_zval(value, value_copy, use_copy);
+   if (use_copy) {
+   value = value_copy;
+   }
+
+   string_printf(str, %sConstant [ %s %s ] { %s }\n,
   indent,
   zend_zval_type_name(value),
-  name);
+  name,
+  Z_STRVAL_P(value));
+
+   if (use_copy) {
+   zval_dtor(value);
+   }
 }
 /* }}} */
 
@@ -4799,7 +4812,7 @@
php_info_print_table_start();
php_info_print_table_header(2, Reflection, enabled);
 
-   php_info_print_table_row(2, Version, $Id: php_reflection.c,v 
1.164.2.33.2.22 2006/09/10 13:25:47 bjori Exp $);
+   php_info_print_table_row(2, Version, $Id: php_reflection.c,v 
1.164.2.33.2.23 2006/09/11 17:08:42 johannes Exp $);
 
php_info_print_table_end();
 } /* }}} */

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



[PHP-CVS] cvs: php-src /ext/reflection php_reflection.c

2006-09-11 Thread Johannes Schl
johannesMon Sep 11 21:21:28 2006 UTC

  Modified files:  
/php-src/ext/reflection php_reflection.c 
  Log:
  - Print the type of the original value
  
http://cvs.php.net/viewvc.cgi/php-src/ext/reflection/php_reflection.c?r1=1.253r2=1.254diff_format=u
Index: php-src/ext/reflection/php_reflection.c
diff -u php-src/ext/reflection/php_reflection.c:1.253 
php-src/ext/reflection/php_reflection.c:1.254
--- php-src/ext/reflection/php_reflection.c:1.253   Mon Sep 11 17:06:59 2006
+++ php-src/ext/reflection/php_reflection.c Mon Sep 11 21:21:27 2006
@@ -20,7 +20,7 @@
+--+
 */
 
-/* $Id: php_reflection.c,v 1.253 2006/09/11 17:06:59 johannes Exp $ */
+/* $Id: php_reflection.c,v 1.254 2006/09/11 21:21:27 johannes Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -530,9 +530,12 @@
 /* {{{ _const_string */
 static void _const_string(string *str, char *name, zval *value, char *indent 
TSRMLS_DC)
 {
+   char *type;
zval value_copy;
int use_copy;
 
+   type = zend_zval_type_name(value);
+
zend_make_printable_zval(value, value_copy, use_copy);
if (use_copy) {
value = value_copy;
@@ -540,7 +543,7 @@
 
string_printf(str, %sConstant [ %s %v ] { %s }\n,
   indent,
-  zend_zval_type_name(value),
+  type,
   name,
   Z_STRVAL_P(value));
 
@@ -4880,7 +4883,7 @@
php_info_print_table_start();
php_info_print_table_header(2, Reflection, enabled);
 
-   php_info_print_table_row(2, Version, $Id: php_reflection.c,v 1.253 
2006/09/11 17:06:59 johannes Exp $);
+   php_info_print_table_row(2, Version, $Id: php_reflection.c,v 1.254 
2006/09/11 21:21:27 johannes Exp $);
 
php_info_print_table_end();
 } /* }}} */

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



[PHP-CVS] cvs: php-src /ext/reflection php_reflection.c

2006-09-17 Thread Johannes Schl
johannesSun Sep 17 09:39:04 2006 UTC

  Modified files:  
/php-src/ext/reflection php_reflection.c 
  Log:
  - Unicode fix
  
http://cvs.php.net/viewvc.cgi/php-src/ext/reflection/php_reflection.c?r1=1.254r2=1.255diff_format=u
Index: php-src/ext/reflection/php_reflection.c
diff -u php-src/ext/reflection/php_reflection.c:1.254 
php-src/ext/reflection/php_reflection.c:1.255
--- php-src/ext/reflection/php_reflection.c:1.254   Mon Sep 11 21:21:27 2006
+++ php-src/ext/reflection/php_reflection.c Sun Sep 17 09:39:04 2006
@@ -20,7 +20,7 @@
+--+
 */
 
-/* $Id: php_reflection.c,v 1.254 2006/09/11 21:21:27 johannes Exp $ */
+/* $Id: php_reflection.c,v 1.255 2006/09/17 09:39:04 johannes Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -3532,8 +3532,7 @@
zval *interface;
ALLOC_ZVAL(interface);
zend_reflection_class_factory(ce-interfaces[i], 
interface TSRMLS_CC);
-   /* FIXME: Unicode support??? */
-   add_assoc_zval_ex(return_value, 
ce-interfaces[i]-name.s, ce-interfaces[i]-name_length + 1, interface);
+   add_u_assoc_zval_ex(return_value, 
UG(unicode)?IS_UNICODE:IS_STRING, ce-interfaces[i]-name, 
ce-interfaces[i]-name_length + 1, interface);
}
}
 }
@@ -4883,7 +4882,7 @@
php_info_print_table_start();
php_info_print_table_header(2, Reflection, enabled);
 
-   php_info_print_table_row(2, Version, $Id: php_reflection.c,v 1.254 
2006/09/11 21:21:27 johannes Exp $);
+   php_info_print_table_row(2, Version, $Id: php_reflection.c,v 1.255 
2006/09/17 09:39:04 johannes Exp $);
 
php_info_print_table_end();
 } /* }}} */

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



[PHP-CVS] cvs: php-src /main php_variables.c

2006-10-21 Thread Johannes Schl
johannesSat Oct 21 10:01:39 2006 UTC

  Modified files:  
/php-src/main   php_variables.c 
  Log:
  - Fix merging of $_REQUEST in unicode mode and remove $GLOBALS check from
register_globals times
  
  
http://cvs.php.net/viewvc.cgi/php-src/main/php_variables.c?r1=1.131r2=1.132diff_format=u
Index: php-src/main/php_variables.c
diff -u php-src/main/php_variables.c:1.131 php-src/main/php_variables.c:1.132
--- php-src/main/php_variables.c:1.131  Tue Sep 19 10:38:31 2006
+++ php-src/main/php_variables.cSat Oct 21 10:01:39 2006
@@ -17,7 +17,7 @@
+--+
  */
 
-/* $Id: php_variables.c,v 1.131 2006/09/19 10:38:31 dmitry Exp $ */
+/* $Id: php_variables.c,v 1.132 2006/10/21 10:01:39 johannes Exp $ */
 
 #include stdio.h
 #include php.h
@@ -770,20 +770,14 @@
zend_hash_internal_pointer_reset_ex(src, pos);
while (zend_hash_get_current_data_ex(src, (void **)src_entry, pos) == 
SUCCESS) {
key_type = zend_hash_get_current_key_ex(src, string_key, 
string_key_len, num_key, 0, pos);
-   /* FIXME: Unicode support??? */
if (Z_TYPE_PP(src_entry) != IS_ARRAY
-   || (key_type == HASH_KEY_IS_STRING  
zend_u_hash_find(dest, key_type, string_key, string_key_len, (void **) 
dest_entry) != SUCCESS)
+   || ((key_type == HASH_KEY_IS_UNICODE || key_type == 
HASH_KEY_IS_STRING)  zend_u_hash_find(dest, key_type, string_key, 
string_key_len, (void **) dest_entry) != SUCCESS)
|| (key_type == HASH_KEY_IS_LONG  
zend_hash_index_find(dest, num_key, (void **)dest_entry) != SUCCESS)
|| Z_TYPE_PP(dest_entry) != IS_ARRAY
 ) {
(*src_entry)-refcount++;
-   if (key_type == HASH_KEY_IS_STRING) {
-   /* prevent overwriting of GLOBALS */
-   if (string_key_len != sizeof(GLOBALS) || 
memcmp(string_key.s, GLOBALS, sizeof(GLOBALS) - 1)) {
-   zend_u_hash_update(dest, key_type, 
string_key, string_key_len, src_entry, sizeof(zval *), NULL);
-   } else {
-   (*src_entry)-refcount--;
-   }
+   if (key_type == HASH_KEY_IS_STRING || key_type == 
HASH_KEY_IS_UNICODE) {
+   zend_u_hash_update(dest, key_type, string_key, 
string_key_len, src_entry, sizeof(zval *), NULL);
} else {
zend_hash_index_update(dest, num_key, 
src_entry, sizeof(zval *), NULL);
}

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



[PHP-CVS] cvs: php-src / NEWS /ext/standard string.c /ext/standard/tests/strings stristr.phpt strstr.phpt

2005-08-09 Thread Johannes Schl
johannesTue Aug  9 16:49:19 2005 EDT

  Added files: 
/php-src/ext/standard/tests/strings stristr.phpt 

  Modified files:  
/php-srcNEWS 
/php-src/ext/standard   string.c 
/php-src/ext/standard/tests/strings strstr.phpt 
  Log:
  - Added option to strstr() and stristr() to get a particular haystack 
component
  
http://cvs.php.net/diff.php/php-src/NEWS?r1=1.2030r2=1.2031ty=u
Index: php-src/NEWS
diff -u php-src/NEWS:1.2030 php-src/NEWS:1.2031
--- php-src/NEWS:1.2030 Tue Aug  9 11:07:18 2005
+++ php-src/NEWSTue Aug  9 16:49:12 2005
@@ -6,6 +6,8 @@
   . Added CURLINFO_HEADER_OUT to facilitate request retrieval.
 - Added an optional parameter to parse_url() to allow retrieval of distinct URL
   components. (Ilia)
+- Added an optional parameter to strstr() and stristr() for retrieval of either
+  the part of haystack before or after first occurence of needle. (Johannes)
 
 ?? ??? 2005, PHP 5.1
 - Upgraded PCRE library to version 6.2. (Andrei)
http://cvs.php.net/diff.php/php-src/ext/standard/string.c?r1=1.445r2=1.446ty=u
Index: php-src/ext/standard/string.c
diff -u php-src/ext/standard/string.c:1.445 php-src/ext/standard/string.c:1.446
--- php-src/ext/standard/string.c:1.445 Wed Aug  3 10:08:13 2005
+++ php-src/ext/standard/string.c   Tue Aug  9 16:49:18 2005
@@ -18,7 +18,7 @@
+--+
  */
 
-/* $Id: string.c,v 1.445 2005/08/03 14:08:13 sniper Exp $ */
+/* $Id: string.c,v 1.446 2005/08/09 20:49:18 johannes Exp $ */
 
 /* Synced with php 3.0 revision 1.193 1999-06-16 [ssb] */
 
@@ -1433,52 +1433,60 @@
 }
 /* }}} */
 
-/* {{{ proto string stristr(string haystack, string needle)
+/* {{{ proto string stristr(string haystack, string needle[, bool part])
Finds first occurrence of a string within another, case insensitive */
 PHP_FUNCTION(stristr)
 {
-   zval **haystack, **needle;
+   char *haystack;
+   long haystack_len;
+   zval *needle;
+   zend_bool part = 0;
char *found = NULL;
int  found_offset;
char *haystack_orig;
char needle_char[2];

-   if (ZEND_NUM_ARGS() != 2 || zend_get_parameters_ex(2, haystack, 
needle) == FAILURE) {
-   WRONG_PARAM_COUNT;
+   if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, sz|b, haystack, 
haystack_len, needle, part) == FAILURE) {
+   return;
}
 
-   SEPARATE_ZVAL(haystack);
-   SEPARATE_ZVAL(needle);
-   
-   convert_to_string_ex(haystack);
+   SEPARATE_ZVAL(needle);
 
-   haystack_orig = estrndup(Z_STRVAL_PP(haystack), Z_STRLEN_PP(haystack));
+   haystack_orig = estrndup(haystack, haystack_len);
 
-   if (Z_TYPE_PP(needle) == IS_STRING) {
-   if (!Z_STRLEN_PP(needle)) {
+   if (Z_TYPE_P(needle) == IS_STRING) {
+   if (!Z_STRLEN_P(needle)) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, Empty 
delimiter.);
efree(haystack_orig);
RETURN_FALSE;
}
 
-   found = php_stristr(Z_STRVAL_PP(haystack),
-   Z_STRVAL_PP(needle),
-   Z_STRLEN_PP(haystack),
-   Z_STRLEN_PP(needle));
+   found = php_stristr(haystack,
+   Z_STRVAL_P(needle),
+   haystack_len,
+   Z_STRLEN_P(needle));
} else {
-   convert_to_long_ex(needle);
-   needle_char[0] = (char) Z_LVAL_PP(needle);
+   convert_to_long_ex(needle);
+   needle_char[0] = (char) Z_LVAL_P(needle);
needle_char[1] = 0;
 
-   found = php_stristr(Z_STRVAL_PP(haystack),
+   found = php_stristr(haystack,
needle_char,
-   Z_STRLEN_PP(haystack),
+   haystack_len,
1);
}
 
if (found) {
-   found_offset = found - Z_STRVAL_PP(haystack);
-   RETVAL_STRINGL(haystack_orig + found_offset, 
Z_STRLEN_PP(haystack) - found_offset, 1);
+   found_offset = found - haystack;
+   if (part) {
+   char *ret;
+   ret = emalloc(found_offset + 1);
+   strncpy(ret, haystack_orig, found_offset);
+   ret[found_offset] = '\0';
+   RETVAL_STRINGL(ret , found_offset, 0);
+   } else {
+   RETVAL_STRINGL(haystack_orig + found_offset, 
haystack_len - found_offset, 

[PHP-CVS] cvs: php-src(PHP_5_1) /sapi/cli php_cli_readline.c

2005-08-14 Thread Johannes Schl
johannesSun Aug 14 09:07:15 2005 EDT

  Modified files:  (Branch: PHP_5_1)
/php-src/sapi/cli   php_cli_readline.c 
  Log:
  - Fix tab-completion for constants.
  
  
http://cvs.php.net/diff.php/php-src/sapi/cli/php_cli_readline.c?r1=1.3r2=1.3.2.1ty=u
Index: php-src/sapi/cli/php_cli_readline.c
diff -u php-src/sapi/cli/php_cli_readline.c:1.3 
php-src/sapi/cli/php_cli_readline.c:1.3.2.1
--- php-src/sapi/cli/php_cli_readline.c:1.3 Mon Jul 25 14:04:13 2005
+++ php-src/sapi/cli/php_cli_readline.c Sun Aug 14 09:07:15 2005
@@ -17,7 +17,7 @@
+--+
 */
 
-/* $Id: php_cli_readline.c,v 1.3 2005/07/25 18:04:13 helly Exp $ */
+/* $Id: php_cli_readline.c,v 1.3.2.1 2005/08/14 13:07:15 johannes Exp $ */
 
 #include php.h
 #include php_globals.h
@@ -396,7 +396,7 @@
}
case 2:
case 3:
-   retval = 
cli_completion_generator_define(lc_text, textlen, cli_completion_state, pce ? 
(*pce)-constants_table : EG(zend_constants) TSRMLS_CC);
+   retval = cli_completion_generator_define(text, 
textlen, cli_completion_state, pce ? (*pce)-constants_table : 
EG(zend_constants) TSRMLS_CC);
if (retval || pce) {
break;
}

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



[PHP-CVS] cvs: php-src /ext/standard string.c

2005-08-15 Thread Johannes Schl
johannesMon Aug 15 15:13:00 2005 EDT

  Modified files:  
/php-src/ext/standard   string.c 
  Log:
  - Fix leak with explode of empty unicode string
  
http://cvs.php.net/diff.php/php-src/ext/standard/string.c?r1=1.452r2=1.453ty=u
Index: php-src/ext/standard/string.c
diff -u php-src/ext/standard/string.c:1.452 php-src/ext/standard/string.c:1.453
--- php-src/ext/standard/string.c:1.452 Mon Aug 15 04:11:35 2005
+++ php-src/ext/standard/string.c   Mon Aug 15 15:12:59 2005
@@ -18,7 +18,7 @@
+--+
  */
 
-/* $Id: string.c,v 1.452 2005/08/15 08:11:35 dmitry Exp $ */
+/* $Id: string.c,v 1.453 2005/08/15 19:12:59 johannes Exp $ */
 
 /* Synced with php 3.0 revision 1.193 1999-06-16 [ssb] */
 
@@ -1097,7 +1097,7 @@
 
if ( str_len == 0 ) {
if ( str_type == IS_UNICODE ) {
-   add_next_index_unicodel(return_value, USTR_MAKE(), 
sizeof()-1, 1);
+   add_next_index_unicodel(return_value, USTR_MAKE(), 
sizeof()-1, 0);
} else if ( str_type == IS_BINARY ) {
add_next_index_binaryl(return_value, , sizeof()-1, 
1);
} else {

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



[PHP-CVS] cvs: php-src /ext/spl php_spl.c

2005-08-24 Thread Johannes Schl
johannesWed Aug 24 06:16:48 2005 EDT

  Modified files:  
/php-src/ext/splphp_spl.c 
  Log:
  - Fix alphabetic order and add missing class
  
http://cvs.php.net/diff.php/php-src/ext/spl/php_spl.c?r1=1.60r2=1.61ty=u
Index: php-src/ext/spl/php_spl.c
diff -u php-src/ext/spl/php_spl.c:1.60 php-src/ext/spl/php_spl.c:1.61
--- php-src/ext/spl/php_spl.c:1.60  Mon Aug 22 09:32:46 2005
+++ php-src/ext/spl/php_spl.c   Wed Aug 24 06:16:45 2005
@@ -16,7 +16,7 @@
+--+
  */
 
-/* $Id: php_spl.c,v 1.60 2005/08/22 13:32:46 dmitry Exp $ */
+/* $Id: php_spl.c,v 1.61 2005/08/24 10:16:45 johannes Exp $ */
 
 #ifdef HAVE_CONFIG_H
#include config.h
@@ -149,8 +149,8 @@
 
 #define SPL_LIST_CLASSES(z_list, sub, allow, ce_flags) \
SPL_ADD_CLASS(AppendIterator, z_list, sub, allow, ce_flags); \
-   SPL_ADD_CLASS(ArrayObject, z_list, sub, allow, ce_flags); \
SPL_ADD_CLASS(ArrayIterator, z_list, sub, allow, ce_flags); \
+   SPL_ADD_CLASS(ArrayObject, z_list, sub, allow, ce_flags); \
SPL_ADD_CLASS(BadFunctionCallException, z_list, sub, allow, ce_flags); \
SPL_ADD_CLASS(BadMethodCallException, z_list, sub, allow, ce_flags); \
SPL_ADD_CLASS(CachingIterator, z_list, sub, allow, ce_flags); \
@@ -170,8 +170,8 @@
SPL_ADD_CLASS(NoRewindIterator, z_list, sub, allow, ce_flags); \
SPL_ADD_CLASS(Observer, z_list, sub, allow, ce_flags); \
SPL_ADD_CLASS(OuterIterator, z_list, sub, allow, ce_flags); \
-   SPL_ADD_CLASS(OutOfRangeException, z_list, sub, allow, ce_flags); \
SPL_ADD_CLASS(OutOfBoundsException, z_list, sub, allow, ce_flags); \
+   SPL_ADD_CLASS(OutOfRangeException, z_list, sub, allow, ce_flags); \
SPL_ADD_CLASS(OverflowException, z_list, sub, allow, ce_flags); \
SPL_ADD_CLASS(ParentIterator, z_list, sub, allow, ce_flags); \
SPL_ADD_CLASS(RangeException, z_list, sub, allow, ce_flags); \
@@ -185,6 +185,7 @@
SPL_ADD_CLASS(SplObjectStorage, z_list, sub, allow, ce_flags); \
SPL_ADD_CLASS(Subject, z_list, sub, allow, ce_flags); \
SPL_ADD_CLASS(UnderflowException, z_list, sub, allow, ce_flags); \
+   SPL_ADD_CLASS(UnexpectedValueException, z_list, sub, allow, ce_flags); \
 
 /* {{{ proto array spl_classes()
  Return an array containing the names of all clsses and interfaces defined in 
SPL */

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



[PHP-CVS] cvs: php-src(PHP_5_1) /ext/spl php_spl.c

2005-08-24 Thread Johannes Schl
johannesWed Aug 24 06:17:44 2005 EDT

  Modified files:  (Branch: PHP_5_1)
/php-src/ext/splphp_spl.c 
  Log:
  - MFH: Fix alphabetic order and add missing class
  
http://cvs.php.net/diff.php/php-src/ext/spl/php_spl.c?r1=1.52.2.2r2=1.52.2.3ty=u
Index: php-src/ext/spl/php_spl.c
diff -u php-src/ext/spl/php_spl.c:1.52.2.2 php-src/ext/spl/php_spl.c:1.52.2.3
--- php-src/ext/spl/php_spl.c:1.52.2.2  Wed Aug 10 04:36:46 2005
+++ php-src/ext/spl/php_spl.c   Wed Aug 24 06:17:43 2005
@@ -16,7 +16,7 @@
+--+
  */
 
-/* $Id: php_spl.c,v 1.52.2.2 2005/08/10 08:36:46 helly Exp $ */
+/* $Id: php_spl.c,v 1.52.2.3 2005/08/24 10:17:43 johannes Exp $ */
 
 #ifdef HAVE_CONFIG_H
#include config.h
@@ -150,8 +150,8 @@
 
 #define SPL_LIST_CLASSES(z_list, sub, allow, ce_flags) \
SPL_ADD_CLASS(AppendIterator, z_list, sub, allow, ce_flags); \
-   SPL_ADD_CLASS(ArrayObject, z_list, sub, allow, ce_flags); \
SPL_ADD_CLASS(ArrayIterator, z_list, sub, allow, ce_flags); \
+   SPL_ADD_CLASS(ArrayObject, z_list, sub, allow, ce_flags); \
SPL_ADD_CLASS(BadFunctionCallException, z_list, sub, allow, ce_flags); \
SPL_ADD_CLASS(BadMethodCallException, z_list, sub, allow, ce_flags); \
SPL_ADD_CLASS(CachingIterator, z_list, sub, allow, ce_flags); \
@@ -171,8 +171,8 @@
SPL_ADD_CLASS(NoRewindIterator, z_list, sub, allow, ce_flags); \
SPL_ADD_CLASS(Observer, z_list, sub, allow, ce_flags); \
SPL_ADD_CLASS(OuterIterator, z_list, sub, allow, ce_flags); \
-   SPL_ADD_CLASS(OutOfRangeException, z_list, sub, allow, ce_flags); \
SPL_ADD_CLASS(OutOfBoundsException, z_list, sub, allow, ce_flags); \
+   SPL_ADD_CLASS(OutOfRangeException, z_list, sub, allow, ce_flags); \
SPL_ADD_CLASS(OverflowException, z_list, sub, allow, ce_flags); \
SPL_ADD_CLASS(ParentIterator, z_list, sub, allow, ce_flags); \
SPL_ADD_CLASS(RangeException, z_list, sub, allow, ce_flags); \
@@ -184,6 +184,7 @@
SPL_ADD_CLASS(SimpleXMLIterator, z_list, sub, allow, ce_flags); \
SPL_ADD_CLASS(Subject, z_list, sub, allow, ce_flags); \
SPL_ADD_CLASS(UnderflowException, z_list, sub, allow, ce_flags); \
+   SPL_ADD_CLASS(UnexpectedValueException, z_list, sub, allow, ce_flags); \
 
 /* {{{ proto array spl_classes()
  Return an array containing the names of all clsses and interfaces defined in 
SPL */

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



[PHP-CVS] cvs: php-src(PHP_5_0) /ext/spl php_spl.c

2005-08-24 Thread Johannes Schl
johannesWed Aug 24 06:18:15 2005 EDT

  Modified files:  (Branch: PHP_5_0)
/php-src/ext/splphp_spl.c 
  Log:
  - MFH: Fix alphabetic order
  
http://cvs.php.net/diff.php/php-src/ext/spl/php_spl.c?r1=1.28r2=1.28.2.1ty=u
Index: php-src/ext/spl/php_spl.c
diff -u php-src/ext/spl/php_spl.c:1.28 php-src/ext/spl/php_spl.c:1.28.2.1
--- php-src/ext/spl/php_spl.c:1.28  Thu Apr 29 19:02:11 2004
+++ php-src/ext/spl/php_spl.c   Wed Aug 24 06:18:15 2005
@@ -16,7 +16,7 @@
+--+
  */
 
-/* $Id: php_spl.c,v 1.28 2004/04/29 23:02:11 helly Exp $ */
+/* $Id: php_spl.c,v 1.28.2.1 2005/08/24 10:18:15 johannes Exp $ */
 
 #ifdef HAVE_CONFIG_H
#include config.h
@@ -157,8 +157,8 @@
spl_add_classes(spl_ce_ ## class_name, z_list, sub, allow, ce_flags 
TSRMLS_CC)
 
 #define SPL_LIST_CLASSES(z_list, sub, allow, ce_flags) \
-   SPL_ADD_CLASS(ArrayObject, z_list, sub, allow, ce_flags); \
SPL_ADD_CLASS(ArrayIterator, z_list, sub, allow, ce_flags); \
+   SPL_ADD_CLASS(ArrayObject, z_list, sub, allow, ce_flags); \
SPL_ADD_CLASS(CachingIterator, z_list, sub, allow, ce_flags); \
SPL_ADD_CLASS(CachingRecursiveIterator, z_list, sub, allow, ce_flags); \
SPL_ADD_CLASS(DirectoryIterator, z_list, sub, allow, ce_flags); \

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



[PHP-CVS] cvs: php-src / NEWS

2005-08-30 Thread Johannes Schl
johannesTue Aug 30 16:02:47 2005 EDT

  Modified files:  
/php-srcNEWS 
  Log:
  News
  
http://cvs.php.net/diff.php/php-src/NEWS?r1=1.2048r2=1.2049ty=u
Index: php-src/NEWS
diff -u php-src/NEWS:1.2048 php-src/NEWS:1.2049
--- php-src/NEWS:1.2048 Tue Aug 30 05:17:56 2005
+++ php-src/NEWSTue Aug 30 16:02:47 2005
@@ -11,6 +11,8 @@
   components. (Ilia)
 - Added an optional parameter to strstr() and stristr() for retrieval of either
   the part of haystack before or after first occurence of needle. (Johannes)
+- Added possibility to check in which extension an internal function was
+  defined using reflection API. (Johannes)
 - Fixed a bug where stream_get_meta_data() did not return the uri element for
   files opened with tmpname(). (Derick)
 - Fixed bug #34302 (date('W') do not return leading zeros for week 1 to 9).

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



[PHP-CVS] cvs: php-src /ext/standard credits.c

2005-09-20 Thread Johannes Schl
johannesTue Sep 20 18:17:35 2005 EDT

  Modified files:  
/php-src/ext/standard   credits.c 
  Log:
  - Remove HTML fragments from phpcredits() in CLI mode
  
http://cvs.php.net/diff.php/php-src/ext/standard/credits.c?r1=1.38r2=1.39ty=u
Index: php-src/ext/standard/credits.c
diff -u php-src/ext/standard/credits.c:1.38 php-src/ext/standard/credits.c:1.39
--- php-src/ext/standard/credits.c:1.38 Thu Aug 11 20:17:26 2005
+++ php-src/ext/standard/credits.c  Tue Sep 20 18:17:34 2005
@@ -17,10 +17,11 @@
+--+
 */
 
-/* $Id: credits.c,v 1.38 2005/08/12 00:17:26 sniper Exp $ */
+/* $Id: credits.c,v 1.39 2005/09/20 22:17:34 johannes Exp $ */
 
 #include php.h
 #include info.h
+#include SAPI.h
 
 #define CREDIT_LINE(module, authors) php_info_print_table_row(2, module, 
authors)
 
@@ -28,11 +29,15 @@
  */
 PHPAPI void php_print_credits(int flag TSRMLS_DC)
 {
-   if (flag  PHP_CREDITS_FULLPAGE) {
+   if (!sapi_module.phpinfo_as_text  flag  PHP_CREDITS_FULLPAGE) {
php_print_info_htmlhead(TSRMLS_C);
}
 
-   PUTS(h1PHP Credits/h1\n);
+   if (!sapi_module.phpinfo_as_text) {
+   PUTS(h1PHP Credits/h1\n);
+   } else {
+   PUTS(PHP Credits\n);
+   }
 
if (flag  PHP_CREDITS_GROUP) {
/* Group */
@@ -46,7 +51,11 @@
if (flag  PHP_CREDITS_GENERAL) {
/* Design  Concept */
php_info_print_table_start();
-   php_info_print_table_header(1, Language Design amp; Concept);
+   if (!sapi_module.phpinfo_as_text) {
+   php_info_print_table_header(1, Language Design amp; 
Concept);
+   } else {
+   php_info_print_table_header(1, Language Design  
Concept);
+   }
php_info_print_table_row(1, Andi Gutmans, Rasmus Lerdorf, Zeev 
Suraski);
php_info_print_table_end();
 
@@ -117,7 +126,7 @@
php_info_print_table_end();
}
 
-   if (flag  PHP_CREDITS_FULLPAGE) {
+   if (!sapi_module.phpinfo_as_text  flag  PHP_CREDITS_FULLPAGE) {
PUTS(/div/body/html\n);
}
 }

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



[PHP-CVS] cvs: php-src(PHP_5_1) /ext/standard credits.c

2005-09-20 Thread Johannes Schl
johannesTue Sep 20 18:19:01 2005 EDT

  Modified files:  (Branch: PHP_5_1)
/php-src/ext/standard   credits.c 
  Log:
  - MFH: Remove HTML fragments from phpcredits() in CLI mode
  
http://cvs.php.net/diff.php/php-src/ext/standard/credits.c?r1=1.36.2.1r2=1.36.2.2ty=u
Index: php-src/ext/standard/credits.c
diff -u php-src/ext/standard/credits.c:1.36.2.1 
php-src/ext/standard/credits.c:1.36.2.2
--- php-src/ext/standard/credits.c:1.36.2.1 Thu Aug 11 17:41:30 2005
+++ php-src/ext/standard/credits.c  Tue Sep 20 18:19:01 2005
@@ -17,10 +17,11 @@
+--+
 */
 
-/* $Id: credits.c,v 1.36.2.1 2005/08/11 21:41:30 helly Exp $ */
+/* $Id: credits.c,v 1.36.2.2 2005/09/20 22:19:01 johannes Exp $ */
 
 #include php.h
 #include info.h
+#include SAPI.h
 
 #define CREDIT_LINE(module, authors) php_info_print_table_row(2, module, 
authors)
 
@@ -28,11 +29,15 @@
  */
 PHPAPI void php_print_credits(int flag TSRMLS_DC)
 {
-   if (flag  PHP_CREDITS_FULLPAGE) {
+   if (!sapi_module.phpinfo_as_text  flag  PHP_CREDITS_FULLPAGE) {
php_print_info_htmlhead(TSRMLS_C);
}
 
-   PUTS(h1PHP Credits/h1\n);
+   if (!sapi_module.phpinfo_as_text) {
+   PUTS(h1PHP Credits/h1\n);
+   } else {
+   PUTS(PHP Credits\n);
+   }
 
if (flag  PHP_CREDITS_GROUP) {
/* Group */
@@ -46,7 +51,11 @@
if (flag  PHP_CREDITS_GENERAL) {
/* Design  Concept */
php_info_print_table_start();
-   php_info_print_table_header(1, Language Design amp; Concept);
+   if (!sapi_module.phpinfo_as_text) {
+   php_info_print_table_header(1, Language Design amp; 
Concept);
+   } else {
+   php_info_print_table_header(1, Language Design  
Concept);
+   }
php_info_print_table_row(1, Andi Gutmans, Rasmus Lerdorf, Zeev 
Suraski);
php_info_print_table_end();
 
@@ -109,7 +118,7 @@
php_info_print_table_end();
}
 
-   if (flag  PHP_CREDITS_FULLPAGE) {
+   if (!sapi_module.phpinfo_as_text  flag  PHP_CREDITS_FULLPAGE) {
PUTS(/div/body/html\n);
}
 }

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



[PHP-CVS] cvs: php-src(PHP_4_4) /ext/standard credits.c

2005-09-20 Thread Johannes Schl
johannesTue Sep 20 18:20:30 2005 EDT

  Modified files:  (Branch: PHP_4_4)
/php-src/ext/standard   credits.c 
  Log:
  - MFH: Remove HTML fragments from phpcredits() in CLI mode
  
http://cvs.php.net/diff.php/php-src/ext/standard/credits.c?r1=1.21.2.6.2.1r2=1.21.2.6.2.2ty=u
Index: php-src/ext/standard/credits.c
diff -u php-src/ext/standard/credits.c:1.21.2.6.2.1 
php-src/ext/standard/credits.c:1.21.2.6.2.2
--- php-src/ext/standard/credits.c:1.21.2.6.2.1 Thu Aug 11 17:37:59 2005
+++ php-src/ext/standard/credits.c  Tue Sep 20 18:20:30 2005
@@ -17,10 +17,11 @@
+--+
 */
 
-/* $Id: credits.c,v 1.21.2.6.2.1 2005/08/11 21:37:59 helly Exp $ */
+/* $Id: credits.c,v 1.21.2.6.2.2 2005/09/20 22:20:30 johannes Exp $ */
 
 #include php.h
 #include info.h
+#include SAPI.h
 
 #define CREDIT_LINE(module, authors) php_info_print_table_row(2, module, 
authors)
 
@@ -30,11 +31,15 @@
 {
TSRMLS_FETCH();
 
-   if (flag  PHP_CREDITS_FULLPAGE) {
+   if (!sapi_module.phpinfo_as_text  flag  PHP_CREDITS_FULLPAGE) {
php_print_info_htmlhead(TSRMLS_C);
}
 
-   PUTS(h1PHP Credits/h1\n);
+   if (!sapi_module.phpinfo_as_text) {
+   PUTS(h1PHP Credits/h1\n);
+   } else {
+   PUTS(PHP Credits\n);
+   }
 
if (flag  PHP_CREDITS_GROUP) {
/* Group */
@@ -48,7 +53,11 @@
if (flag  PHP_CREDITS_GENERAL) {
/* Design  Concept */
php_info_print_table_start();
-   php_info_print_table_header(1, Language Design amp; Concept);
+   if (!sapi_module.phpinfo_as_text) {
+   php_info_print_table_header(1, Language Design amp; 
Concept);
+   } else {
+   php_info_print_table_header(1, Language Design  
Concept);
+   }
php_info_print_table_row(1, Andi Gutmans, Rasmus Lerdorf, Zeev 
Suraski);
php_info_print_table_end();
 
@@ -110,7 +119,7 @@
php_info_print_table_end();
}
 
-   if (flag  PHP_CREDITS_FULLPAGE) {
+   if (!sapi_module.phpinfo_as_text  flag  PHP_CREDITS_FULLPAGE) {
PUTS(/div/body/html\n);
}
 }

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



[PHP-CVS] cvs: php-src / NEWS /sapi/cli php_cli.c

2005-10-03 Thread Johannes Schl
johannesMon Oct  3 07:54:49 2005 EDT

  Modified files:  
/php-srcNEWS 
/php-src/sapi/cli   php_cli.c 
  Log:
  - Add --rclass and --rextension arguments to CLI
  
http://cvs.php.net/diff.php/php-src/NEWS?r1=1.2067r2=1.2068ty=u
Index: php-src/NEWS
diff -u php-src/NEWS:1.2067 php-src/NEWS:1.2068
--- php-src/NEWS:1.2067 Tue Sep 27 04:25:34 2005
+++ php-src/NEWSMon Oct  3 07:54:46 2005
@@ -17,4 +17,6 @@
   the part of haystack before or after first occurence of needle. (Johannes)
 - Added possibility to check in which extension an internal function was
   defined using reflection API. (Johannes)
+- Added --rclass and --rextension CLI arguments to reflect internal classes and
+  loaded extensions (Johannes)
 - Fixed bug #34286 (__toString() behavior is inconsistent). (Marcus)
http://cvs.php.net/diff.php/php-src/sapi/cli/php_cli.c?r1=1.129r2=1.130ty=u
Index: php-src/sapi/cli/php_cli.c
diff -u php-src/sapi/cli/php_cli.c:1.129 php-src/sapi/cli/php_cli.c:1.130
--- php-src/sapi/cli/php_cli.c:1.129Mon Aug  8 12:49:44 2005
+++ php-src/sapi/cli/php_cli.c  Mon Oct  3 07:54:46 2005
@@ -20,13 +20,15 @@
+--+
 */
 
-/* $Id: php_cli.c,v 1.129 2005/08/08 16:49:44 sniper Exp $ */
+/* $Id: php_cli.c,v 1.130 2005/10/03 11:54:46 johannes Exp $ */
 
 #include php.h
 #include php_globals.h
 #include php_variables.h
 #include zend_hash.h
 #include zend_modules.h
+#include zend_interfaces.h
+#include zend_reflection_api.h
 
 #include SAPI.h
 
@@ -97,6 +99,8 @@
 #define PHP_MODE_STRIP 5
 #define PHP_MODE_CLI_DIRECT6
 #define PHP_MODE_PROCESS_STDIN 7
+#define PHP_MODE_REFLECTION_CLASS   8
+#define PHP_MODE_REFLECTION_EXTENSION   9
 
 static char *php_optarg = NULL;
 static int php_optind = 1;
@@ -130,6 +134,8 @@
{'?', 0, usage},/* help alias (both '?' and 'usage') */
{'v', 0, version},
{'z', 1, zend-extension},
+   {10,  1, rclass},
+   {11,  1, rextension},
{'-', 0, NULL} /* end of args */
 };
 
@@ -562,6 +568,7 @@
zend_file_handle file_handle;
 /* temporary locals */
int behavior=PHP_MODE_STANDARD;
+   char *reflection_what;
int orig_optind=php_optind;
char *orig_optarg=php_optarg;
char *arg_free=NULL, **arg_excp=arg_free;
@@ -897,6 +904,15 @@
hide_argv = 1;
break;
 
+   case 10:
+   behavior=PHP_MODE_REFLECTION_CLASS;
+   reflection_what = php_optarg;
+   break;
+   case 11:
+   behavior=PHP_MODE_REFLECTION_EXTENSION;
+   reflection_what = php_optarg;
+   break;
+
default:
break;
}
@@ -1130,6 +1146,56 @@
}

break;
+   case PHP_MODE_REFLECTION_CLASS:
+   case PHP_MODE_REFLECTION_EXTENSION:
+   {
+   zend_class_entry *reflection_ce;
+   zval *arg;
+   
+   if (behavior == 
PHP_MODE_REFLECTION_CLASS) {
+   zend_class_entry **ppce;
+
+   if 
(zend_lookup_class(reflection_what, strlen(reflection_what), ppce TSRMLS_CC) 
== FAILURE) {
+   zend_printf(Class %s 
not found\n, reflection_what);
+   exit_status=254;
+
+   break;
+   }
+
+   reflection_ce = 
reflection_class_ptr;
+   } else if (behavior == 
PHP_MODE_REFLECTION_EXTENSION) {
+   char *lcname = 
do_alloca(strlen(reflection_what) + 1);
+   struct _zend_module_entry 
*module;
+
+   zend_str_tolower_copy(lcname, 
reflection_what, strlen(reflection_what));
+   if 
(zend_hash_find(module_registry, lcname,  strlen(reflection_what) + 1, (void 
**)module) == FAILURE) {
+   zend_printf(Extension 
%s not found\n, reflection_what);
+
+   free_alloca(lcname);
+
+   exit_status=254;
+   break;
+  

[PHP-CVS] cvs: php-src /sapi/cgi cgi_main.c /sapi/cli php_cli.c

2005-10-06 Thread Johannes Schl
johannesThu Oct  6 16:29:14 2005 EDT

  Modified files:  
/php-src/sapi/cgi   cgi_main.c 
/php-src/sapi/cli   php_cli.c 
  Log:
  - Fix #34557 php -m exits with error 1
  
http://cvs.php.net/diff.php/php-src/sapi/cgi/cgi_main.c?r1=1.267r2=1.268ty=u
Index: php-src/sapi/cgi/cgi_main.c
diff -u php-src/sapi/cgi/cgi_main.c:1.267 php-src/sapi/cgi/cgi_main.c:1.268
--- php-src/sapi/cgi/cgi_main.c:1.267   Wed Aug  3 07:12:17 2005
+++ php-src/sapi/cgi/cgi_main.c Thu Oct  6 16:29:09 2005
@@ -20,7 +20,7 @@
+--+
 */
 
-/* $Id: cgi_main.c,v 1.267 2005/08/03 11:12:17 sniper Exp $ */
+/* $Id: cgi_main.c,v 1.268 2005/10/06 20:29:09 johannes Exp $ */
 
 #include php.h
 #include php_globals.h
@@ -1366,7 +1366,7 @@
}
php_print_info(0x 
TSRMLS_CC);
php_end_ob_buffers(1 TSRMLS_CC);
-   exit(1);
+   exit(0);
break;
 
case 'l': /* syntax check mode */
@@ -1384,7 +1384,7 @@
print_extensions(TSRMLS_C);
php_printf(\n);
php_end_ob_buffers(1 TSRMLS_CC);
-   exit(1);
+   exit(0);
break;
 
 #if 0 /* not yet operational, see also below ... */
@@ -1417,7 +1417,7 @@
php_printf(PHP %s (%s) (built: 
%s %s)\nCopyright (c) 1997-2005 The PHP Group\n%s, PHP_VERSION, 
sapi_module.name, __DATE__, __TIME__, get_zend_version());
 #endif
php_end_ob_buffers(1 TSRMLS_CC);
-   exit(1);
+   exit(0);
break;
 
case 'w':
http://cvs.php.net/diff.php/php-src/sapi/cli/php_cli.c?r1=1.130r2=1.131ty=u
Index: php-src/sapi/cli/php_cli.c
diff -u php-src/sapi/cli/php_cli.c:1.130 php-src/sapi/cli/php_cli.c:1.131
--- php-src/sapi/cli/php_cli.c:1.130Mon Oct  3 07:54:46 2005
+++ php-src/sapi/cli/php_cli.c  Thu Oct  6 16:29:13 2005
@@ -20,7 +20,7 @@
+--+
 */
 
-/* $Id: php_cli.c,v 1.130 2005/10/03 11:54:46 johannes Exp $ */
+/* $Id: php_cli.c,v 1.131 2005/10/06 20:29:13 johannes Exp $ */
 
 #include php.h
 #include php_globals.h
@@ -704,8 +704,9 @@
php_output_activate(TSRMLS_C);
php_cli_usage(argv[0]);
php_end_ob_buffers(1 TSRMLS_CC);
-   exit_status=1;
-   goto err;
+   exit_status=0;
+   zend_ini_deactivate(TSRMLS_C);
+   goto out_err;
 
 
case 'i': /* php info  quit */
@@ -714,7 +715,7 @@
}
php_print_info(0x TSRMLS_CC);
php_end_ob_buffers(1 TSRMLS_CC);
-   exit_status=1;
+   exit_status=0;
goto out;
 
case 'm': /* list compiled in modules */
@@ -726,8 +727,9 @@
print_extensions(TSRMLS_C);
php_printf(\n);
php_end_ob_buffers(1 TSRMLS_CC);
-   exit_status=1;
-   goto err;
+   exit_status=0;
+   zend_ini_deactivate(TSRMLS_C);
+   goto out_err;
 
case 'v': /* show php version  quit */
if (php_request_startup(TSRMLS_C)==FAILURE) {
@@ -739,7 +741,7 @@
php_printf(PHP %s (%s) (built: %s 
%s)\nCopyright (c) 1997-2005 The PHP Group\n%s, PHP_VERSION, sapi_module.name, 
__DATE__, __TIME__, get_zend_version());
 #endif
php_end_ob_buffers(1 TSRMLS_CC);
-   exit_status=1;
+   exit_status=0;
goto out;
 
default:

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



[PHP-CVS] cvs: php-src(PHP_5_1) /sapi/cgi cgi_main.c /sapi/cli php_cli.c

2005-10-06 Thread Johannes Schl
johannesThu Oct  6 16:29:41 2005 EDT

  Modified files:  (Branch: PHP_5_1)
/php-src/sapi/cgi   cgi_main.c 
/php-src/sapi/cli   php_cli.c 
  Log:
  - MFH: Fix #34557 php -m exits with error 1
  
http://cvs.php.net/diff.php/php-src/sapi/cgi/cgi_main.c?r1=1.267r2=1.267.2.1ty=u
Index: php-src/sapi/cgi/cgi_main.c
diff -u php-src/sapi/cgi/cgi_main.c:1.267 php-src/sapi/cgi/cgi_main.c:1.267.2.1
--- php-src/sapi/cgi/cgi_main.c:1.267   Wed Aug  3 07:12:17 2005
+++ php-src/sapi/cgi/cgi_main.c Thu Oct  6 16:29:40 2005
@@ -20,7 +20,7 @@
+--+
 */
 
-/* $Id: cgi_main.c,v 1.267 2005/08/03 11:12:17 sniper Exp $ */
+/* $Id: cgi_main.c,v 1.267.2.1 2005/10/06 20:29:40 johannes Exp $ */
 
 #include php.h
 #include php_globals.h
@@ -1366,7 +1366,7 @@
}
php_print_info(0x 
TSRMLS_CC);
php_end_ob_buffers(1 TSRMLS_CC);
-   exit(1);
+   exit(0);
break;
 
case 'l': /* syntax check mode */
@@ -1384,7 +1384,7 @@
print_extensions(TSRMLS_C);
php_printf(\n);
php_end_ob_buffers(1 TSRMLS_CC);
-   exit(1);
+   exit(0);
break;
 
 #if 0 /* not yet operational, see also below ... */
@@ -1417,7 +1417,7 @@
php_printf(PHP %s (%s) (built: 
%s %s)\nCopyright (c) 1997-2005 The PHP Group\n%s, PHP_VERSION, 
sapi_module.name, __DATE__, __TIME__, get_zend_version());
 #endif
php_end_ob_buffers(1 TSRMLS_CC);
-   exit(1);
+   exit(0);
break;
 
case 'w':
http://cvs.php.net/diff.php/php-src/sapi/cli/php_cli.c?r1=1.129r2=1.129.2.1ty=u
Index: php-src/sapi/cli/php_cli.c
diff -u php-src/sapi/cli/php_cli.c:1.129 php-src/sapi/cli/php_cli.c:1.129.2.1
--- php-src/sapi/cli/php_cli.c:1.129Mon Aug  8 12:49:44 2005
+++ php-src/sapi/cli/php_cli.c  Thu Oct  6 16:29:41 2005
@@ -20,7 +20,7 @@
+--+
 */
 
-/* $Id: php_cli.c,v 1.129 2005/08/08 16:49:44 sniper Exp $ */
+/* $Id: php_cli.c,v 1.129.2.1 2005/10/06 20:29:41 johannes Exp $ */
 
 #include php.h
 #include php_globals.h
@@ -697,8 +697,9 @@
php_output_activate(TSRMLS_C);
php_cli_usage(argv[0]);
php_end_ob_buffers(1 TSRMLS_CC);
-   exit_status=1;
-   goto err;
+   exit_status=0;
+   zend_ini_deactivate(TSRMLS_C);
+   goto out_err;
 
 
case 'i': /* php info  quit */
@@ -707,7 +708,7 @@
}
php_print_info(0x TSRMLS_CC);
php_end_ob_buffers(1 TSRMLS_CC);
-   exit_status=1;
+   exit_status=0;
goto out;
 
case 'm': /* list compiled in modules */
@@ -719,8 +720,9 @@
print_extensions(TSRMLS_C);
php_printf(\n);
php_end_ob_buffers(1 TSRMLS_CC);
-   exit_status=1;
-   goto err;
+   exit_status=0;
+   zend_ini_deactivate(TSRMLS_C);
+   goto out_err;
 
case 'v': /* show php version  quit */
if (php_request_startup(TSRMLS_C)==FAILURE) {
@@ -732,7 +734,7 @@
php_printf(PHP %s (%s) (built: %s 
%s)\nCopyright (c) 1997-2005 The PHP Group\n%s, PHP_VERSION, sapi_module.name, 
__DATE__, __TIME__, get_zend_version());
 #endif
php_end_ob_buffers(1 TSRMLS_CC);
-   exit_status=1;
+   exit_status=0;
goto out;
 
default:

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



[PHP-CVS] cvs: php-src(PHP_5_0) / NEWS /sapi/cgi cgi_main.c /sapi/cli php_cli.c

2005-10-06 Thread Johannes Schl
johannesThu Oct  6 16:36:46 2005 EDT

  Modified files:  (Branch: PHP_5_0)
/php-srcNEWS 
/php-src/sapi/cgi   cgi_main.c 
/php-src/sapi/cli   php_cli.c 
  Log:
  - MFH: Fix #34557 php -m exits with error 1
  
http://cvs.php.net/diff.php/php-src/NEWS?r1=1.1760.2.490r2=1.1760.2.491ty=u
Index: php-src/NEWS
diff -u php-src/NEWS:1.1760.2.490 php-src/NEWS:1.1760.2.491
--- php-src/NEWS:1.1760.2.490   Tue Oct  4 16:49:33 2005
+++ php-src/NEWSThu Oct  6 16:36:42 2005
@@ -7,6 +7,7 @@
 - Fixed bug #34643 (wsdl default value has no effect). (Dmitry)
 - Fixed bug #34617 (zend_deactivate: objects_store used after
   zend_objects_store_destroy is called). (Dmitry)
+- Fixed bug #34557 (php -m exits with error 1). (Johannes)
 - Fixed bug #34505 (Possible memory corruption when unmangling properties 
   with empty names). (Tony)
 - Fixed bug #34478 (Incorrect parsing of url's fragment (#...)). (Dmitry)
http://cvs.php.net/diff.php/php-src/sapi/cgi/cgi_main.c?r1=1.256.2.6r2=1.256.2.7ty=u
Index: php-src/sapi/cgi/cgi_main.c
diff -u php-src/sapi/cgi/cgi_main.c:1.256.2.6 
php-src/sapi/cgi/cgi_main.c:1.256.2.7
--- php-src/sapi/cgi/cgi_main.c:1.256.2.6   Thu Apr 28 10:24:21 2005
+++ php-src/sapi/cgi/cgi_main.c Thu Oct  6 16:36:44 2005
@@ -20,7 +20,7 @@
+--+
 */
 
-/* $Id: cgi_main.c,v 1.256.2.6 2005/04/28 14:24:21 sniper Exp $ */
+/* $Id: cgi_main.c,v 1.256.2.7 2005/10/06 20:36:44 johannes Exp $ */
 
 #include php.h
 #include php_globals.h
@@ -1374,7 +1374,7 @@
}
php_print_info(0x 
TSRMLS_CC);
php_end_ob_buffers(1 TSRMLS_CC);
-   exit(1);
+   exit(0);
break;
 
case 'l': /* syntax check mode */
@@ -1392,7 +1392,7 @@
print_extensions(TSRMLS_C);
php_printf(\n);
php_end_ob_buffers(1 TSRMLS_CC);
-   exit(1);
+   exit(0);
break;
 
 #if 0 /* not yet operational, see also below ... */
@@ -1425,7 +1425,7 @@
php_printf(PHP %s (%s) (built: 
%s %s)\nCopyright (c) 1997-2004 The PHP Group\n%s, PHP_VERSION, 
sapi_module.name, __DATE__, __TIME__, get_zend_version());
 #endif
php_end_ob_buffers(1 TSRMLS_CC);
-   exit(1);
+   exit(0);
break;
 
case 'w':
http://cvs.php.net/diff.php/php-src/sapi/cli/php_cli.c?r1=1.113.2.2r2=1.113.2.3ty=u
Index: php-src/sapi/cli/php_cli.c
diff -u php-src/sapi/cli/php_cli.c:1.113.2.2 
php-src/sapi/cli/php_cli.c:1.113.2.3
--- php-src/sapi/cli/php_cli.c:1.113.2.2Tue Mar 22 10:09:20 2005
+++ php-src/sapi/cli/php_cli.c  Thu Oct  6 16:36:45 2005
@@ -19,7 +19,7 @@
+--+
 */
 
-/* $Id: php_cli.c,v 1.113.2.2 2005/03/22 15:09:20 tony2001 Exp $ */
+/* $Id: php_cli.c,v 1.113.2.3 2005/10/06 20:36:45 johannes Exp $ */
 
 #include php.h
 #include php_globals.h
@@ -665,8 +665,9 @@
php_output_activate(TSRMLS_C);
php_cli_usage(argv[0]);
php_end_ob_buffers(1 TSRMLS_CC);
-   exit_status=1;
-   goto err;
+   exit_status=0;
+   zend_ini_deactivate(TSRMLS_C);
+   goto out_err;
 
 
case 'i': /* php info  quit */
@@ -675,7 +676,7 @@
}
php_print_info(0x TSRMLS_CC);
php_end_ob_buffers(1 TSRMLS_CC);
-   exit_status=1;
+   exit_status=0;
goto out;
 
case 'm': /* list compiled in modules */
@@ -687,8 +688,9 @@
print_extensions(TSRMLS_C);
php_printf(\n);
php_end_ob_buffers(1 TSRMLS_CC);
-   exit_status=1;
-   goto err;
+   exit_status=0;
+   zend_ini_deactivate(TSRMLS_C);
+   goto out_err;
 
case 'v': /* show php version  

[PHP-CVS] cvs: php-src(PHP_4_4) / NEWS /sapi/cgi cgi_main.c /sapi/cli php_cli.c

2005-10-06 Thread Johannes Schl
johannesThu Oct  6 16:39:29 2005 EDT

  Modified files:  (Branch: PHP_4_4)
/php-srcNEWS 
/php-src/sapi/cgi   cgi_main.c 
/php-src/sapi/cli   php_cli.c 
  Log:
  - MFH: Fix #34557 php -m exits with error 1
  
http://cvs.php.net/diff.php/php-src/NEWS?r1=1.1247.2.920.2.47r2=1.1247.2.920.2.48ty=u
Index: php-src/NEWS
diff -u php-src/NEWS:1.1247.2.920.2.47 php-src/NEWS:1.1247.2.920.2.48
--- php-src/NEWS:1.1247.2.920.2.47  Wed Oct  5 10:34:38 2005
+++ php-src/NEWSThu Oct  6 16:39:24 2005
@@ -13,6 +13,7 @@
 - Fixed bug #34645 (ctype corrupts memory when validating large numbers). 
(Ilia)
 - Fixed bug #34565 (mb_send_mail does not fetch mail.force_extra_parameters).
   (Marco, Ilia)
+- Fixed bug #34557 (php -m exits with error 1). (Johannes)
 - Fixed bug #34456 (Possible crash inside pspell extension). (Nuno)
 - Fixed bug #34311 (unserialize() crashes with chars above 191 dec). (Nuno)
 - Fixed bug #34307 (on_modify handler not called to set the default value if
http://cvs.php.net/diff.php/php-src/sapi/cgi/cgi_main.c?r1=1.190.2.68r2=1.190.2.68.2.1ty=u
Index: php-src/sapi/cgi/cgi_main.c
diff -u php-src/sapi/cgi/cgi_main.c:1.190.2.68 
php-src/sapi/cgi/cgi_main.c:1.190.2.68.2.1
--- php-src/sapi/cgi/cgi_main.c:1.190.2.68  Thu Apr 28 10:24:47 2005
+++ php-src/sapi/cgi/cgi_main.c Thu Oct  6 16:39:26 2005
@@ -20,7 +20,7 @@
+--+
 */
 
-/* $Id: cgi_main.c,v 1.190.2.68 2005/04/28 14:24:47 sniper Exp $ */
+/* $Id: cgi_main.c,v 1.190.2.68.2.1 2005/10/06 20:39:26 johannes Exp $ */
 
 #include php.h
 #include php_globals.h
@@ -1395,7 +1395,7 @@
}
php_print_info(0x 
TSRMLS_CC);
php_end_ob_buffers(1 TSRMLS_CC);
-   exit(1);
+   exit(0);
break;
 
case 'l': /* syntax check mode */
@@ -1413,7 +1413,7 @@
print_extensions(TSRMLS_C);
php_printf(\n);
php_end_ob_buffers(1 TSRMLS_CC);
-   exit(1);
+   exit(0);
break;
 
 #if 0 /* not yet operational, see also below ... */
@@ -1446,7 +1446,7 @@
php_printf(PHP %s (%s) (built: 
%s %s)\nCopyright (c) 1997-2004 The PHP Group\n%s, PHP_VERSION, 
sapi_module.name, __DATE__, __TIME__, get_zend_version());
 #endif
php_end_ob_buffers(1 TSRMLS_CC);
-   exit(1);
+   exit(0);
break;
 
case 'w': 
http://cvs.php.net/diff.php/php-src/sapi/cli/php_cli.c?r1=1.51.2.37r2=1.51.2.37.2.1ty=u
Index: php-src/sapi/cli/php_cli.c
diff -u php-src/sapi/cli/php_cli.c:1.51.2.37 
php-src/sapi/cli/php_cli.c:1.51.2.37.2.1
--- php-src/sapi/cli/php_cli.c:1.51.2.37Tue Mar 22 10:09:36 2005
+++ php-src/sapi/cli/php_cli.c  Thu Oct  6 16:39:26 2005
@@ -623,8 +623,9 @@
php_output_activate(TSRMLS_C);
php_cli_usage(argv[0]);
php_end_ob_buffers(1 TSRMLS_CC);
-   exit_status=1;
-   goto err;
+   exit_status=0;
+   zend_ini_deactivate(TSRMLS_C);
+   goto out_err;
 
 
case 'i': /* php info  quit */
@@ -633,7 +634,7 @@
}
php_print_info(0x TSRMLS_CC);
php_end_ob_buffers(1 TSRMLS_CC);
-   exit_status=1;
+   exit_status=0;
goto out;
 
case 'm': /* list compiled in modules */
@@ -645,8 +646,9 @@
print_extensions(TSRMLS_C);
php_printf(\n);
php_end_ob_buffers(1 TSRMLS_CC);
-   exit_status=1;
-   goto err;
+   exit_status=0;
+   zend_ini_deactivate(TSRMLS_C);
+   goto out_err;
 
case 'v': /* show php version  quit */
if (php_request_startup(TSRMLS_C)==FAILURE) {
@@ -658,7 +660,7 @@
php_printf(PHP %s (%s) (built: %s 

[PHP-CVS] cvs: php-src /ext/spl php_spl.c

2005-11-20 Thread Johannes Schl
johannesSun Nov 20 10:21:24 2005 EDT

  Modified files:  
/php-src/ext/splphp_spl.c 
  Log:
  - Fix SPL class listing for phpinfo in unicode mode
  
http://cvs.php.net/diff.php/php-src/ext/spl/php_spl.c?r1=1.75r2=1.76ty=u
Index: php-src/ext/spl/php_spl.c
diff -u php-src/ext/spl/php_spl.c:1.75 php-src/ext/spl/php_spl.c:1.76
--- php-src/ext/spl/php_spl.c:1.75  Thu Nov  3 17:04:35 2005
+++ php-src/ext/spl/php_spl.c   Sun Nov 20 10:21:23 2005
@@ -16,7 +16,7 @@
+--+
  */
 
-/* $Id: php_spl.c,v 1.75 2005/11/03 22:04:35 helly Exp $ */
+/* $Id: php_spl.c,v 1.76 2005/11/20 15:21:23 johannes Exp $ */
 
 #ifdef HAVE_CONFIG_H
#include config.h
@@ -559,7 +559,7 @@
 {
char *res;

-   spprintf(res, 0, %s, %s, *list, Z_STRVAL_PP(entry));
+   spprintf(res, 0, %s, %v, *list, Z_STRVAL_PP(entry));
efree(*list);
*list = res;
return ZEND_HASH_APPLY_KEEP;

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



[PHP-CVS] cvs: php-src / NEWS /ext/reflection php_reflection.c

2005-11-23 Thread Johannes Schl
johannesWed Nov 23 15:47:43 2005 EDT

  Modified files:  
/php-srcNEWS 
/php-src/ext/reflection php_reflection.c 
  Log:
  Changed reflection constants to class constants
  
http://cvs.php.net/diff.php/php-src/NEWS?r1=1.2085r2=1.2086ty=u
Index: php-src/NEWS
diff -u php-src/NEWS:1.2085 php-src/NEWS:1.2086
--- php-src/NEWS:1.2085 Wed Nov 23 13:08:46 2005
+++ php-src/NEWSWed Nov 23 15:47:41 2005
@@ -10,6 +10,7 @@
   (Marcus, Dmitry)
 - Changed instanceof and catch operators, is_a() and is_subclass_of()
   functions to not call __autoload(). (Dmitry)
+- Changed reflection constants to class constants. (Johannes)
 - Added allow_url_include ini directive to be able to turn off remote url
   code execution separately from the allow_url_fopen setting. (Rasmus)
 - Added --enable-gcov configure option to enable C-level code coverage.
http://cvs.php.net/diff.php/php-src/ext/reflection/php_reflection.c?r1=1.192r2=1.193ty=u
Index: php-src/ext/reflection/php_reflection.c
diff -u php-src/ext/reflection/php_reflection.c:1.192 
php-src/ext/reflection/php_reflection.c:1.193
--- php-src/ext/reflection/php_reflection.c:1.192   Mon Nov 21 05:57:28 2005
+++ php-src/ext/reflection/php_reflection.c Wed Nov 23 15:47:42 2005
@@ -19,7 +19,7 @@
+--+
 */
 
-/* $Id: php_reflection.c,v 1.192 2005/11/21 10:57:28 dmitry Exp $ */
+/* $Id: php_reflection.c,v 1.193 2005/11/23 20:47:42 johannes Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -103,6 +103,10 @@
}   
\
target = intern-ptr;   
\
 
+/* Class constants */
+#define REGISTER_REFLECTION_CLASS_CONST_LONG(class_name, const_name, value)
\
+   zend_declare_class_constant_long(reflection_ ## class_name ## _ptr, 
const_name, sizeof(const_name)-1, (long)value TSRMLS_CC);
+
 /* {{{ Smart string functions */
 typedef struct _string {
char *string;
@@ -4225,12 +4229,23 @@
zend_declare_property_string(reflection_method_ptr, name, 
sizeof(name)-1, , ZEND_ACC_PUBLIC TSRMLS_CC);
zend_declare_property_string(reflection_method_ptr, class, 
sizeof(class)-1, , ZEND_ACC_PUBLIC TSRMLS_CC);
 
+   REGISTER_REFLECTION_CLASS_CONST_LONG(method, STATIC, ZEND_ACC_STATIC);
+   REGISTER_REFLECTION_CLASS_CONST_LONG(method, PUBLIC, ZEND_ACC_PUBLIC);
+   REGISTER_REFLECTION_CLASS_CONST_LONG(method, PROTECTED, 
ZEND_ACC_PROTECTED);
+   REGISTER_REFLECTION_CLASS_CONST_LONG(method, PRIVATE, 
ZEND_ACC_PRIVATE);
+   REGISTER_REFLECTION_CLASS_CONST_LONG(method, ABSTRACT, 
ZEND_ACC_ABSTRACT);
+   REGISTER_REFLECTION_CLASS_CONST_LONG(method, FINAL, ZEND_ACC_FINAL);
+
INIT_CLASS_ENTRY(_reflection_entry, ReflectionClass, 
reflection_class_functions);
_reflection_entry.create_object = reflection_objects_new;
reflection_class_ptr = zend_register_internal_class(_reflection_entry 
TSRMLS_CC);
reflection_register_implement(reflection_class_ptr, reflector_ptr 
TSRMLS_CC);
zend_declare_property_string(reflection_class_ptr, name, 
sizeof(name)-1, , ZEND_ACC_PUBLIC TSRMLS_CC);
 
+   REGISTER_REFLECTION_CLASS_CONST_LONG(class, IMPLICIT_ABSTRACT, 
ZEND_ACC_IMPLICIT_ABSTRACT_CLASS);
+   REGISTER_REFLECTION_CLASS_CONST_LONG(class, EXPLICIT_ABSTRACT, 
ZEND_ACC_EXPLICIT_ABSTRACT_CLASS);
+   REGISTER_REFLECTION_CLASS_CONST_LONG(class, FINAL, 
ZEND_ACC_FINAL_CLASS);
+
INIT_CLASS_ENTRY(_reflection_entry, ReflectionObject, 
reflection_object_functions);
_reflection_entry.create_object = reflection_objects_new;
reflection_object_ptr = 
zend_register_internal_class_ex(_reflection_entry, reflection_class_ptr, NULL 
TSRMLS_CC);
@@ -4242,31 +4257,17 @@
zend_declare_property_string(reflection_property_ptr, name, 
sizeof(name)-1, , ZEND_ACC_PUBLIC TSRMLS_CC);
zend_declare_property_string(reflection_property_ptr, class, 
sizeof(class)-1, , ZEND_ACC_PUBLIC TSRMLS_CC);
 
+   REGISTER_REFLECTION_CLASS_CONST_LONG(property, STATIC, 
ZEND_ACC_STATIC);
+   REGISTER_REFLECTION_CLASS_CONST_LONG(property, PUBLIC, 
ZEND_ACC_PUBLIC);
+   REGISTER_REFLECTION_CLASS_CONST_LONG(property, PROTECTED, 
ZEND_ACC_PROTECTED);
+   REGISTER_REFLECTION_CLASS_CONST_LONG(property, PRIVATE, 
ZEND_ACC_PRIVATE);
+
INIT_CLASS_ENTRY(_reflection_entry, ReflectionExtension, 
reflection_extension_functions);
_reflection_entry.create_object = reflection_objects_new;
reflection_extension_ptr = 
zend_register_internal_class(_reflection_entry TSRMLS_CC);
reflection_register_implement(reflection_extension_ptr, reflector_ptr 
TSRMLS_CC);
zend_declare_property_string(reflection_extension_ptr, name, 
sizeof(name)-1, , 

[PHP-CVS] cvs: php-src /win32 sendmail.c /win32/build template.rc

2006-02-08 Thread Johannes Schl
johannesWed Feb  8 21:03:00 2006 UTC

  Modified files:  
/php-src/win32  sendmail.c 
/php-src/win32/buildtemplate.rc 
  Log:
  - It's 2006 and PHP 6
  
http://cvs.php.net/viewcvs.cgi/php-src/win32/sendmail.c?r1=1.66r2=1.67diff_format=u
Index: php-src/win32/sendmail.c
diff -u php-src/win32/sendmail.c:1.66 php-src/win32/sendmail.c:1.67
--- php-src/win32/sendmail.c:1.66   Fri Jan  6 02:04:22 2006
+++ php-src/win32/sendmail.cWed Feb  8 21:03:00 2006
@@ -17,7 +17,7 @@
  *
  */
 
-/* $Id: sendmail.c,v 1.66 2006/01/06 02:04:22 sniper Exp $ */
+/* $Id: sendmail.c,v 1.67 2006/02/08 21:03:00 johannes Exp $ */
 
 #include php.h   /*php specific */
 #include stdio.h
@@ -85,9 +85,9 @@
 #endif
 char seps[] =  ,\t\n;
 #ifndef NETWARE
-char *php_mailer = PHP 4 WIN32;
+char *php_mailer = PHP 6 WIN32;
 #else
-char *php_mailer = PHP 4 NetWare;
+char *php_mailer = PHP 6 NetWare;
 #endif /* NETWARE */
 
 /* Error messages */
http://cvs.php.net/viewcvs.cgi/php-src/win32/build/template.rc?r1=1.7r2=1.8diff_format=u
Index: php-src/win32/build/template.rc
diff -u php-src/win32/build/template.rc:1.7 php-src/win32/build/template.rc:1.8
--- php-src/win32/build/template.rc:1.7 Wed Aug  3 14:08:58 2005
+++ php-src/win32/build/template.rc Wed Feb  8 21:03:00 2006
@@ -1,5 +1,5 @@
 /* This is a template RC file.
- * $Id: template.rc,v 1.7 2005/08/03 14:08:58 sniper Exp $
+ * $Id: template.rc,v 1.8 2006/02/08 21:03:00 johannes Exp $
  * Do not edit with MSVC */
 #ifdef APSTUDIO_INVOKED
 # error dont edit with MSVC
@@ -47,7 +47,7 @@
 VALUE FileDescription, FILE_DESCRIPTION \0
 VALUE FileVersion, STRVER4(PHP_MAJOR_VERSION, PHP_MINOR_VERSION, 
PHP_RELEASE_VERSION, PHP_RELEASE_VERSION)
 VALUE InternalName, FILE_NAME \0
-VALUE LegalCopyright, Copyright © 1997-2005 The PHP Group\0
+VALUE LegalCopyright, Copyright  1997-2006 The PHP Group\0
 VALUE LegalTrademarks, PHP\0
 VALUE OriginalFilename, FILE_NAME \0
 VALUE PrivateBuild, \0

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



[PHP-CVS] cvs: php-src(PHP_5_1) /win32 sendmail.c /win32/build template.rc

2006-02-08 Thread Johannes Schl
johannesWed Feb  8 21:03:36 2006 UTC

  Modified files:  (Branch: PHP_5_1)
/php-src/win32  sendmail.c 
/php-src/win32/buildtemplate.rc 
  Log:
  - MFH: It's 2006 and PHP 5
  
http://cvs.php.net/viewcvs.cgi/php-src/win32/sendmail.c?r1=1.65.2.1r2=1.65.2.2diff_format=u
Index: php-src/win32/sendmail.c
diff -u php-src/win32/sendmail.c:1.65.2.1 php-src/win32/sendmail.c:1.65.2.2
--- php-src/win32/sendmail.c:1.65.2.1   Fri Jan  6 02:04:33 2006
+++ php-src/win32/sendmail.cWed Feb  8 21:03:36 2006
@@ -17,7 +17,7 @@
  *
  */
 
-/* $Id: sendmail.c,v 1.65.2.1 2006/01/06 02:04:33 sniper Exp $ */
+/* $Id: sendmail.c,v 1.65.2.2 2006/02/08 21:03:36 johannes Exp $ */
 
 #include php.h   /*php specific */
 #include stdio.h
@@ -85,9 +85,9 @@
 #endif
 char seps[] =  ,\t\n;
 #ifndef NETWARE
-char *php_mailer = PHP 4 WIN32;
+char *php_mailer = PHP 5 WIN32;
 #else
-char *php_mailer = PHP 4 NetWare;
+char *php_mailer = PHP 5 NetWare;
 #endif /* NETWARE */
 
 /* Error messages */
http://cvs.php.net/viewcvs.cgi/php-src/win32/build/template.rc?r1=1.7r2=1.7.2.1diff_format=u
Index: php-src/win32/build/template.rc
diff -u php-src/win32/build/template.rc:1.7 
php-src/win32/build/template.rc:1.7.2.1
--- php-src/win32/build/template.rc:1.7 Wed Aug  3 14:08:58 2005
+++ php-src/win32/build/template.rc Wed Feb  8 21:03:36 2006
@@ -1,5 +1,5 @@
 /* This is a template RC file.
- * $Id: template.rc,v 1.7 2005/08/03 14:08:58 sniper Exp $
+ * $Id: template.rc,v 1.7.2.1 2006/02/08 21:03:36 johannes Exp $
  * Do not edit with MSVC */
 #ifdef APSTUDIO_INVOKED
 # error dont edit with MSVC
@@ -47,7 +47,7 @@
 VALUE FileDescription, FILE_DESCRIPTION \0
 VALUE FileVersion, STRVER4(PHP_MAJOR_VERSION, PHP_MINOR_VERSION, 
PHP_RELEASE_VERSION, PHP_RELEASE_VERSION)
 VALUE InternalName, FILE_NAME \0
-VALUE LegalCopyright, Copyright © 1997-2005 The PHP Group\0
+VALUE LegalCopyright, Copyright  1997-2006 The PHP Group\0
 VALUE LegalTrademarks, PHP\0
 VALUE OriginalFilename, FILE_NAME \0
 VALUE PrivateBuild, \0

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



[PHP-CVS] cvs: php-src /win32/build template.rc

2006-02-08 Thread Johannes Schl
johannesWed Feb  8 21:07:42 2006 UTC

  Modified files:  
/php-src/win32/buildtemplate.rc 
  Log:
  - Fix charset
  
http://cvs.php.net/viewcvs.cgi/php-src/win32/build/template.rc?r1=1.8r2=1.9diff_format=u
Index: php-src/win32/build/template.rc
diff -u php-src/win32/build/template.rc:1.8 php-src/win32/build/template.rc:1.9
--- php-src/win32/build/template.rc:1.8 Wed Feb  8 21:03:00 2006
+++ php-src/win32/build/template.rc Wed Feb  8 21:07:41 2006
@@ -1,5 +1,5 @@
 /* This is a template RC file.
- * $Id: template.rc,v 1.8 2006/02/08 21:03:00 johannes Exp $
+ * $Id: template.rc,v 1.9 2006/02/08 21:07:41 johannes Exp $
  * Do not edit with MSVC */
 #ifdef APSTUDIO_INVOKED
 # error dont edit with MSVC
@@ -47,7 +47,7 @@
 VALUE FileDescription, FILE_DESCRIPTION \0
 VALUE FileVersion, STRVER4(PHP_MAJOR_VERSION, PHP_MINOR_VERSION, 
PHP_RELEASE_VERSION, PHP_RELEASE_VERSION)
 VALUE InternalName, FILE_NAME \0
-VALUE LegalCopyright, Copyright  1997-2006 The PHP Group\0
+VALUE LegalCopyright, Copyright © 1997-2006 The PHP Group\0
 VALUE LegalTrademarks, PHP\0
 VALUE OriginalFilename, FILE_NAME \0
 VALUE PrivateBuild, \0

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



[PHP-CVS] cvs: php-src(PHP_5_1) /win32/build template.rc

2006-02-08 Thread Johannes Schl
johannesWed Feb  8 21:09:18 2006 UTC

  Modified files:  (Branch: PHP_5_1)
/php-src/win32/buildtemplate.rc 
  Log:
  - MFH: Fix charset
  
http://cvs.php.net/viewcvs.cgi/php-src/win32/build/template.rc?r1=1.7.2.1r2=1.7.2.2diff_format=u
Index: php-src/win32/build/template.rc
diff -u php-src/win32/build/template.rc:1.7.2.1 
php-src/win32/build/template.rc:1.7.2.2
--- php-src/win32/build/template.rc:1.7.2.1 Wed Feb  8 21:03:36 2006
+++ php-src/win32/build/template.rc Wed Feb  8 21:09:18 2006
@@ -1,5 +1,5 @@
 /* This is a template RC file.
- * $Id: template.rc,v 1.7.2.1 2006/02/08 21:03:36 johannes Exp $
+ * $Id: template.rc,v 1.7.2.2 2006/02/08 21:09:18 johannes Exp $
  * Do not edit with MSVC */
 #ifdef APSTUDIO_INVOKED
 # error dont edit with MSVC
@@ -47,7 +47,7 @@
 VALUE FileDescription, FILE_DESCRIPTION \0
 VALUE FileVersion, STRVER4(PHP_MAJOR_VERSION, PHP_MINOR_VERSION, 
PHP_RELEASE_VERSION, PHP_RELEASE_VERSION)
 VALUE InternalName, FILE_NAME \0
-VALUE LegalCopyright, Copyright  1997-2006 The PHP Group\0
+VALUE LegalCopyright, Copyright © 1997-2006 The PHP Group\0
 VALUE LegalTrademarks, PHP\0
 VALUE OriginalFilename, FILE_NAME \0
 VALUE PrivateBuild, \0

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



[PHP-CVS] cvs: php-src /ext/reflection php_reflection.c

2006-02-20 Thread Johannes Schl
johannesMon Feb 20 23:31:29 2006 UTC

  Modified files:  
/php-src/ext/reflection php_reflection.c 
  Log:
  - Rename reflection constants to fix parser conflicts
  
http://cvs.php.net/viewcvs.cgi/php-src/ext/reflection/php_reflection.c?r1=1.210r2=1.211diff_format=u
Index: php-src/ext/reflection/php_reflection.c
diff -u php-src/ext/reflection/php_reflection.c:1.210 
php-src/ext/reflection/php_reflection.c:1.211
--- php-src/ext/reflection/php_reflection.c:1.210   Mon Feb 20 23:26:39 2006
+++ php-src/ext/reflection/php_reflection.c Mon Feb 20 23:31:29 2006
@@ -20,7 +20,7 @@
+--+
 */
 
-/* $Id: php_reflection.c,v 1.210 2006/02/20 23:26:39 helly Exp $ */
+/* $Id: php_reflection.c,v 1.211 2006/02/20 23:31:29 johannes Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -4386,12 +4386,12 @@
zend_declare_property_string(reflection_method_ptr, name, 
sizeof(name)-1, , ZEND_ACC_PUBLIC TSRMLS_CC);
zend_declare_property_string(reflection_method_ptr, class, 
sizeof(class)-1, , ZEND_ACC_PUBLIC TSRMLS_CC);
 
-   REGISTER_REFLECTION_CLASS_CONST_LONG(method, STATIC, ZEND_ACC_STATIC);
-   REGISTER_REFLECTION_CLASS_CONST_LONG(method, PUBLIC, ZEND_ACC_PUBLIC);
-   REGISTER_REFLECTION_CLASS_CONST_LONG(method, PROTECTED, 
ZEND_ACC_PROTECTED);
-   REGISTER_REFLECTION_CLASS_CONST_LONG(method, PRIVATE, 
ZEND_ACC_PRIVATE);
-   REGISTER_REFLECTION_CLASS_CONST_LONG(method, ABSTRACT, 
ZEND_ACC_ABSTRACT);
-   REGISTER_REFLECTION_CLASS_CONST_LONG(method, FINAL, ZEND_ACC_FINAL);
+   REGISTER_REFLECTION_CLASS_CONST_LONG(method, IS_STATIC, 
ZEND_ACC_STATIC);
+   REGISTER_REFLECTION_CLASS_CONST_LONG(method, IS_PUBLIC, 
ZEND_ACC_PUBLIC);
+   REGISTER_REFLECTION_CLASS_CONST_LONG(method, IS_PROTECTED, 
ZEND_ACC_PROTECTED);
+   REGISTER_REFLECTION_CLASS_CONST_LONG(method, IS_PRIVATE, 
ZEND_ACC_PRIVATE);
+   REGISTER_REFLECTION_CLASS_CONST_LONG(method, IS_ABSTRACT, 
ZEND_ACC_ABSTRACT);
+   REGISTER_REFLECTION_CLASS_CONST_LONG(method, IS_FINAL, 
ZEND_ACC_FINAL);
 
INIT_CLASS_ENTRY(_reflection_entry, ReflectionClass, 
reflection_class_functions);
_reflection_entry.create_object = reflection_objects_new;
@@ -4399,9 +4399,9 @@
reflection_register_implement(reflection_class_ptr, reflector_ptr 
TSRMLS_CC);
zend_declare_property_string(reflection_class_ptr, name, 
sizeof(name)-1, , ZEND_ACC_PUBLIC TSRMLS_CC);
 
-   REGISTER_REFLECTION_CLASS_CONST_LONG(class, IMPLICIT_ABSTRACT, 
ZEND_ACC_IMPLICIT_ABSTRACT_CLASS);
-   REGISTER_REFLECTION_CLASS_CONST_LONG(class, EXPLICIT_ABSTRACT, 
ZEND_ACC_EXPLICIT_ABSTRACT_CLASS);
-   REGISTER_REFLECTION_CLASS_CONST_LONG(class, FINAL, 
ZEND_ACC_FINAL_CLASS);
+   REGISTER_REFLECTION_CLASS_CONST_LONG(class, IS_IMPLICIT_ABSTRACT, 
ZEND_ACC_IMPLICIT_ABSTRACT_CLASS);
+   REGISTER_REFLECTION_CLASS_CONST_LONG(class, IS_EXPLICIT_ABSTRACT, 
ZEND_ACC_EXPLICIT_ABSTRACT_CLASS);
+   REGISTER_REFLECTION_CLASS_CONST_LONG(class, IS_FINAL, 
ZEND_ACC_FINAL_CLASS);
 
INIT_CLASS_ENTRY(_reflection_entry, ReflectionObject, 
reflection_object_functions);
_reflection_entry.create_object = reflection_objects_new;
@@ -4414,10 +4414,10 @@
zend_declare_property_string(reflection_property_ptr, name, 
sizeof(name)-1, , ZEND_ACC_PUBLIC TSRMLS_CC);
zend_declare_property_string(reflection_property_ptr, class, 
sizeof(class)-1, , ZEND_ACC_PUBLIC TSRMLS_CC);
 
-   REGISTER_REFLECTION_CLASS_CONST_LONG(property, STATIC, 
ZEND_ACC_STATIC);
-   REGISTER_REFLECTION_CLASS_CONST_LONG(property, PUBLIC, 
ZEND_ACC_PUBLIC);
-   REGISTER_REFLECTION_CLASS_CONST_LONG(property, PROTECTED, 
ZEND_ACC_PROTECTED);
-   REGISTER_REFLECTION_CLASS_CONST_LONG(property, PRIVATE, 
ZEND_ACC_PRIVATE);
+   REGISTER_REFLECTION_CLASS_CONST_LONG(property, IS_STATIC, 
ZEND_ACC_STATIC);
+   REGISTER_REFLECTION_CLASS_CONST_LONG(property, IS_PUBLIC, 
ZEND_ACC_PUBLIC);
+   REGISTER_REFLECTION_CLASS_CONST_LONG(property, IS_PROTECTED, 
ZEND_ACC_PROTECTED);
+   REGISTER_REFLECTION_CLASS_CONST_LONG(property, IS_PRIVATE, 
ZEND_ACC_PRIVATE);
 
INIT_CLASS_ENTRY(_reflection_entry, ReflectionExtension, 
reflection_extension_functions);
_reflection_entry.create_object = reflection_objects_new;
@@ -4433,7 +4433,7 @@
php_info_print_table_start();
php_info_print_table_header(2, Reflection, enabled);
 
-   php_info_print_table_row(2, Version, $Id: php_reflection.c,v 1.210 
2006/02/20 23:26:39 helly Exp $);
+   php_info_print_table_row(2, Version, $Id: php_reflection.c,v 1.211 
2006/02/20 23:31:29 johannes Exp $);
 
php_info_print_table_end();
 } /* }}} */

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



[PHP-CVS] cvs: php-src(PHP_5_1) / NEWS /ext/reflection php_reflection.c

2006-02-20 Thread Johannes Schl
johannesMon Feb 20 23:33:33 2006 UTC

  Modified files:  (Branch: PHP_5_1)
/php-src/ext/reflection php_reflection.c 
/php-srcNEWS 
  Log:
  - MFH: Rename reflection constants to fix parser conflicts
  
http://cvs.php.net/viewcvs.cgi/php-src/ext/reflection/php_reflection.c?r1=1.164.2.24r2=1.164.2.25diff_format=u
Index: php-src/ext/reflection/php_reflection.c
diff -u php-src/ext/reflection/php_reflection.c:1.164.2.24 
php-src/ext/reflection/php_reflection.c:1.164.2.25
--- php-src/ext/reflection/php_reflection.c:1.164.2.24  Mon Feb 20 15:27:45 2006
+++ php-src/ext/reflection/php_reflection.c Mon Feb 20 23:33:32 2006
@@ -20,7 +20,7 @@
+--+
 */
 
-/* $Id: php_reflection.c,v 1.164.2.24 2006/02/20 15:27:45 iliaa Exp $ */
+/* $Id: php_reflection.c,v 1.164.2.25 2006/02/20 23:33:32 johannes Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -4282,12 +4282,12 @@
zend_declare_property_string(reflection_method_ptr, name, 
sizeof(name)-1, , ZEND_ACC_PUBLIC TSRMLS_CC);
zend_declare_property_string(reflection_method_ptr, class, 
sizeof(class)-1, , ZEND_ACC_PUBLIC TSRMLS_CC);
 
-   REGISTER_REFLECTION_CLASS_CONST_LONG(method, STATIC, ZEND_ACC_STATIC);
-   REGISTER_REFLECTION_CLASS_CONST_LONG(method, PUBLIC, ZEND_ACC_PUBLIC);
-   REGISTER_REFLECTION_CLASS_CONST_LONG(method, PROTECTED, 
ZEND_ACC_PROTECTED);
-   REGISTER_REFLECTION_CLASS_CONST_LONG(method, PRIVATE, 
ZEND_ACC_PRIVATE);
-   REGISTER_REFLECTION_CLASS_CONST_LONG(method, ABSTRACT, 
ZEND_ACC_ABSTRACT);
-   REGISTER_REFLECTION_CLASS_CONST_LONG(method, FINAL, ZEND_ACC_FINAL);
+   REGISTER_REFLECTION_CLASS_CONST_LONG(method, IS_STATIC, 
ZEND_ACC_STATIC);
+   REGISTER_REFLECTION_CLASS_CONST_LONG(method, IS_PUBLIC, 
ZEND_ACC_PUBLIC);
+   REGISTER_REFLECTION_CLASS_CONST_LONG(method, IS_PROTECTED, 
ZEND_ACC_PROTECTED);
+   REGISTER_REFLECTION_CLASS_CONST_LONG(method, IS_PRIVATE, 
ZEND_ACC_PRIVATE);
+   REGISTER_REFLECTION_CLASS_CONST_LONG(method, IS_ABSTRACT, 
ZEND_ACC_ABSTRACT);
+   REGISTER_REFLECTION_CLASS_CONST_LONG(method, IS_FINAL, 
ZEND_ACC_FINAL);
 
INIT_CLASS_ENTRY(_reflection_entry, ReflectionClass, 
reflection_class_functions);
_reflection_entry.create_object = reflection_objects_new;
@@ -4295,9 +4295,9 @@
reflection_register_implement(reflection_class_ptr, reflector_ptr 
TSRMLS_CC);
zend_declare_property_string(reflection_class_ptr, name, 
sizeof(name)-1, , ZEND_ACC_PUBLIC TSRMLS_CC);
 
-   REGISTER_REFLECTION_CLASS_CONST_LONG(class, IMPLICIT_ABSTRACT, 
ZEND_ACC_IMPLICIT_ABSTRACT_CLASS);
-   REGISTER_REFLECTION_CLASS_CONST_LONG(class, EXPLICIT_ABSTRACT, 
ZEND_ACC_EXPLICIT_ABSTRACT_CLASS);
-   REGISTER_REFLECTION_CLASS_CONST_LONG(class, FINAL, 
ZEND_ACC_FINAL_CLASS);
+   REGISTER_REFLECTION_CLASS_CONST_LONG(class, IS_IMPLICIT_ABSTRACT, 
ZEND_ACC_IMPLICIT_ABSTRACT_CLASS);
+   REGISTER_REFLECTION_CLASS_CONST_LONG(class, IS_EXPLICIT_ABSTRACT, 
ZEND_ACC_EXPLICIT_ABSTRACT_CLASS);
+   REGISTER_REFLECTION_CLASS_CONST_LONG(class, IS_FINAL, 
ZEND_ACC_FINAL_CLASS);
 
INIT_CLASS_ENTRY(_reflection_entry, ReflectionObject, 
reflection_object_functions);
_reflection_entry.create_object = reflection_objects_new;
@@ -4310,10 +4310,10 @@
zend_declare_property_string(reflection_property_ptr, name, 
sizeof(name)-1, , ZEND_ACC_PUBLIC TSRMLS_CC);
zend_declare_property_string(reflection_property_ptr, class, 
sizeof(class)-1, , ZEND_ACC_PUBLIC TSRMLS_CC);
 
-   REGISTER_REFLECTION_CLASS_CONST_LONG(property, STATIC, 
ZEND_ACC_STATIC);
-   REGISTER_REFLECTION_CLASS_CONST_LONG(property, PUBLIC, 
ZEND_ACC_PUBLIC);
-   REGISTER_REFLECTION_CLASS_CONST_LONG(property, PROTECTED, 
ZEND_ACC_PROTECTED);
-   REGISTER_REFLECTION_CLASS_CONST_LONG(property, PRIVATE, 
ZEND_ACC_PRIVATE);
+   REGISTER_REFLECTION_CLASS_CONST_LONG(property, IS_STATIC, 
ZEND_ACC_STATIC);
+   REGISTER_REFLECTION_CLASS_CONST_LONG(property, IS_PUBLIC, 
ZEND_ACC_PUBLIC);
+   REGISTER_REFLECTION_CLASS_CONST_LONG(property, IS_PROTECTED, 
ZEND_ACC_PROTECTED);
+   REGISTER_REFLECTION_CLASS_CONST_LONG(property, IS_PRIVATE, 
ZEND_ACC_PRIVATE);
 
INIT_CLASS_ENTRY(_reflection_entry, ReflectionExtension, 
reflection_extension_functions);
_reflection_entry.create_object = reflection_objects_new;
@@ -4329,7 +4329,7 @@
php_info_print_table_start();
php_info_print_table_header(2, Reflection, enabled);
 
-   php_info_print_table_row(2, Version, $Id: php_reflection.c,v 
1.164.2.24 2006/02/20 15:27:45 iliaa Exp $);
+   php_info_print_table_row(2, Version, $Id: php_reflection.c,v 
1.164.2.25 2006/02/20 23:33:32 johannes Exp $);
 
php_info_print_table_end();
 } /* }}} */
http://cvs.php.net/viewcvs.cgi/php-src/NEWS?r1=1.2027.2.421r2=1.2027.2.422diff_format=u
Index: php-src/NEWS
diff -u 

[PHP-CVS] cvs: php-src /sapi/cli php_cli_readline.c

2006-02-21 Thread Johannes Schl
johannesTue Feb 21 21:04:19 2006 UTC

  Modified files:  
/php-src/sapi/cli   php_cli_readline.c 
  Log:
  - Fix build with readline-support
  
http://cvs.php.net/viewcvs.cgi/php-src/sapi/cli/php_cli_readline.c?r1=1.8r2=1.9diff_format=u
Index: php-src/sapi/cli/php_cli_readline.c
diff -u php-src/sapi/cli/php_cli_readline.c:1.8 
php-src/sapi/cli/php_cli_readline.c:1.9
--- php-src/sapi/cli/php_cli_readline.c:1.8 Sun Jan  1 13:09:58 2006
+++ php-src/sapi/cli/php_cli_readline.c Tue Feb 21 21:04:19 2006
@@ -17,7 +17,7 @@
+--+
 */
 
-/* $Id: php_cli_readline.c,v 1.8 2006/01/01 13:09:58 sniper Exp $ */
+/* $Id: php_cli_readline.c,v 1.9 2006/02/21 21:04:19 johannes Exp $ */
 
 #include php.h
 
@@ -344,14 +344,14 @@
int32_t tmp_len, len;
UErrorCode status = U_ZERO_ERROR;
 
-   len = u_strlen((UChar *)func-common.function_name);
+   len = u_strlen((UChar *)func-common.function_name.u);

zend_convert_from_unicode(ZEND_U_CONVERTER(UG(output_encoding_conv)), tmp, 
tmp_len,
- 
(UChar *)func-common.function_name, len, status);
+ 
(UChar *)func-common.function_name.u, len, status);
 
retval = strdup(tmp);
efree(tmp);
} else {
-   retval = strdup(func-common.function_name);
+   retval = strdup(func-common.function_name.s);
}
}

@@ -370,14 +370,14 @@
int32_t tmp_len, len;
UErrorCode status = U_ZERO_ERROR;
 
-   len = u_strlen((UChar *)(*pce)-name);
+   len = u_strlen((UChar *)(*pce)-name.u);

zend_convert_from_unicode(ZEND_U_CONVERTER(UG(output_encoding_conv)), tmp, 
tmp_len, 
- 
(UChar *)(*pce)-name, len, status);
+ 
(UChar *)(*pce)-name.u, len, status);
 
retval = strdup(tmp);
efree(tmp);
} else {
-   retval = strdup((*pce)-name);
+   retval = strdup((*pce)-name.s);
}
}

@@ -479,7 +479,7 @@
if (pce  retval) {
char *tmp = malloc(class_name_len + 2 + strlen(retval) 
+ 1);

-   sprintf(tmp, %s::%s, (*pce)-name, retval);
+   sprintf(tmp, %s::%s, (*pce)-name.s, retval);
free(retval);
retval = tmp;
}

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



[PHP-CVS] cvs: php-src /sapi/cli php_cli.c

2006-02-21 Thread Johannes Schl
johannesTue Feb 21 21:14:36 2006 UTC

  Modified files:  
/php-src/sapi/cli   php_cli.c 
  Log:
  - List --rf/--rc/--re only with enabled reflection
  
http://cvs.php.net/viewcvs.cgi/php-src/sapi/cli/php_cli.c?r1=1.146r2=1.147diff_format=u
Index: php-src/sapi/cli/php_cli.c
diff -u php-src/sapi/cli/php_cli.c:1.146 php-src/sapi/cli/php_cli.c:1.147
--- php-src/sapi/cli/php_cli.c:1.146Tue Feb 21 20:12:43 2006
+++ php-src/sapi/cli/php_cli.c  Tue Feb 21 21:14:36 2006
@@ -20,7 +20,7 @@
+--+
 */
 
-/* $Id: php_cli.c,v 1.146 2006/02/21 20:12:43 dmitry Exp $ */
+/* $Id: php_cli.c,v 1.147 2006/02/21 21:14:36 johannes Exp $ */
 
 #include php.h
 #include php_globals.h
@@ -438,10 +438,12 @@
  args...  Arguments passed to script. 
Use -- args when first argument\n
   starts with - or script is 
read from stdin\n
\n
+#if (HAVE_REFLECTION)
  --rf name  Show information about 
function name.\n
  --rc name  Show information about 
class name.\n
  --re name  Show information about 
extension name.\n
\n
+#endif
, prog, prog, prog, prog, prog, prog);
 }
 /* }}} */

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



[PHP-CVS] cvs: php-src(PHP_5_1) /sapi/cli php_cli.c

2006-02-21 Thread Johannes Schl
johannesTue Feb 21 21:15:13 2006 UTC

  Modified files:  (Branch: PHP_5_1)
/php-src/sapi/cli   php_cli.c 
  Log:
  - MFH: List --rf/--rc/--re only with enabled reflection
  
http://cvs.php.net/viewcvs.cgi/php-src/sapi/cli/php_cli.c?r1=1.129.2.12r2=1.129.2.13diff_format=u
Index: php-src/sapi/cli/php_cli.c
diff -u php-src/sapi/cli/php_cli.c:1.129.2.12 
php-src/sapi/cli/php_cli.c:1.129.2.13
--- php-src/sapi/cli/php_cli.c:1.129.2.12   Sun Jan 22 22:09:54 2006
+++ php-src/sapi/cli/php_cli.c  Tue Feb 21 21:15:13 2006
@@ -20,7 +20,7 @@
+--+
 */
 
-/* $Id: php_cli.c,v 1.129.2.12 2006/01/22 22:09:54 helly Exp $ */
+/* $Id: php_cli.c,v 1.129.2.13 2006/02/21 21:15:13 johannes Exp $ */
 
 #include php.h
 #include php_globals.h
@@ -434,10 +434,12 @@
  args...  Arguments passed to script. 
Use -- args when first argument\n
   starts with - or script is 
read from stdin\n
\n
+#if (HAVE_REFLECTION)
  --rf name  Show information about 
function name.\n
  --rc name  Show information about 
class name.\n
  --re name  Show information about 
extension name.\n
\n
+#endif
, prog, prog, prog, prog, prog, prog);
 }
 /* }}} */

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



[PHP-CVS] cvs: php-src /ext/reflection php_reflection.c

2006-02-21 Thread Johannes Schl
johannesTue Feb 21 21:42:54 2006 UTC

  Modified files:  
/php-src/ext/reflection php_reflection.c 
  Log:
  - Print deprecation info on reflection export
  
http://cvs.php.net/viewcvs.cgi/php-src/ext/reflection/php_reflection.c?r1=1.217r2=1.218diff_format=u
Index: php-src/ext/reflection/php_reflection.c
diff -u php-src/ext/reflection/php_reflection.c:1.217 
php-src/ext/reflection/php_reflection.c:1.218
--- php-src/ext/reflection/php_reflection.c:1.217   Tue Feb 21 21:38:28 2006
+++ php-src/ext/reflection/php_reflection.c Tue Feb 21 21:42:54 2006
@@ -20,7 +20,7 @@
+--+
 */
 
-/* $Id: php_reflection.c,v 1.217 2006/02/21 21:38:28 sebastian Exp $ */
+/* $Id: php_reflection.c,v 1.218 2006/02/21 21:42:54 johannes Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -707,6 +707,9 @@
}
string_printf(str,  );
 
+   if (fptr-common.fn_flags  ZEND_ACC_DEPRECATED) {
+   string_printf(str, DEPRECATED );
+   }
if (fptr-common.fn_flags  ZEND_ACC_ABSTRACT) {
string_printf(str, abstract );
}
@@ -4493,7 +4496,7 @@
php_info_print_table_start();
php_info_print_table_header(2, Reflection, enabled);
 
-   php_info_print_table_row(2, Version, $Id: php_reflection.c,v 1.217 
2006/02/21 21:38:28 sebastian Exp $);
+   php_info_print_table_row(2, Version, $Id: php_reflection.c,v 1.218 
2006/02/21 21:42:54 johannes Exp $);
 
php_info_print_table_end();
 } /* }}} */

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



[PHP-CVS] cvs: php-src /ext/reflection php_reflection.c

2006-02-24 Thread Johannes Schl
johannesFri Feb 24 13:44:46 2006 UTC

  Modified files:  
/php-src/ext/reflection php_reflection.c 
  Log:
  - deprecated not static
  
http://cvs.php.net/viewcvs.cgi/php-src/ext/reflection/php_reflection.c?r1=1.220r2=1.221diff_format=u
Index: php-src/ext/reflection/php_reflection.c
diff -u php-src/ext/reflection/php_reflection.c:1.220 
php-src/ext/reflection/php_reflection.c:1.221
--- php-src/ext/reflection/php_reflection.c:1.220   Fri Feb 24 13:37:20 2006
+++ php-src/ext/reflection/php_reflection.c Fri Feb 24 13:44:46 2006
@@ -20,7 +20,7 @@
+--+
 */
 
-/* $Id: php_reflection.c,v 1.220 2006/02/24 13:37:20 helly Exp $ */
+/* $Id: php_reflection.c,v 1.221 2006/02/24 13:44:46 johannes Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -4438,7 +4438,7 @@
reflection_register_implement(reflection_function_ptr, reflector_ptr 
TSRMLS_CC);
zend_declare_property_string(reflection_function_ptr, name, 
sizeof(name)-1, , ZEND_ACC_PUBLIC TSRMLS_CC);
 
-   REGISTER_REFLECTION_CLASS_CONST_LONG(function, IS_STATIC, 
ZEND_ACC_DEPRECATED);
+   REGISTER_REFLECTION_CLASS_CONST_LONG(function, IS_DEPRECATED, 
ZEND_ACC_DEPRECATED);
 
INIT_CLASS_ENTRY(_reflection_entry, ReflectionParameter, 
reflection_parameter_functions);
_reflection_entry.create_object = reflection_objects_new;
@@ -4499,7 +4499,7 @@
php_info_print_table_start();
php_info_print_table_header(2, Reflection, enabled);
 
-   php_info_print_table_row(2, Version, $Id: php_reflection.c,v 1.220 
2006/02/24 13:37:20 helly Exp $);
+   php_info_print_table_row(2, Version, $Id: php_reflection.c,v 1.221 
2006/02/24 13:44:46 johannes Exp $);
 
php_info_print_table_end();
 } /* }}} */

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



[PHP-CVS] cvs: php-src /ext/reflection php_reflection.c /ext/reflection/tests bug29986.phpt

2006-02-24 Thread Johannes Schl
johannesFri Feb 24 23:08:36 2006 UTC

  Added files: 
/php-src/ext/reflection/tests   bug29986.phpt 

  Modified files:  
/php-src/ext/reflection php_reflection.c 
  Log:
  - Fix #29986 (Class constants won't work with predefined constants when
using ReflectionClass)
  
http://cvs.php.net/viewcvs.cgi/php-src/ext/reflection/php_reflection.c?r1=1.221r2=1.222diff_format=u
Index: php-src/ext/reflection/php_reflection.c
diff -u php-src/ext/reflection/php_reflection.c:1.221 
php-src/ext/reflection/php_reflection.c:1.222
--- php-src/ext/reflection/php_reflection.c:1.221   Fri Feb 24 13:44:46 2006
+++ php-src/ext/reflection/php_reflection.c Fri Feb 24 23:08:36 2006
@@ -20,7 +20,7 @@
+--+
 */
 
-/* $Id: php_reflection.c,v 1.221 2006/02/24 13:44:46 johannes Exp $ */
+/* $Id: php_reflection.c,v 1.222 2006/02/24 23:08:36 johannes Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -347,6 +347,7 @@
 
/* Constants */
if (ce-constants_table) {
+   zend_hash_apply_with_argument(ce-constants_table, 
(apply_func_arg_t) zval_update_constant, (void*)1 TSRMLS_CC);
string_printf(str, \n);
count = zend_hash_num_elements(ce-constants_table);
string_printf(str, %s  - Constants [%d] {\n, indent, count);
@@ -4499,7 +4500,7 @@
php_info_print_table_start();
php_info_print_table_header(2, Reflection, enabled);
 
-   php_info_print_table_row(2, Version, $Id: php_reflection.c,v 1.221 
2006/02/24 13:44:46 johannes Exp $);
+   php_info_print_table_row(2, Version, $Id: php_reflection.c,v 1.222 
2006/02/24 23:08:36 johannes Exp $);
 
php_info_print_table_end();
 } /* }}} */

http://cvs.php.net/viewcvs.cgi/php-src/ext/reflection/tests/bug29986.phpt?view=markuprev=1.1
Index: php-src/ext/reflection/tests/bug29986.phpt
+++ php-src/ext/reflection/tests/bug29986.phpt
--TEST--
Reflection::export
--SKIPIF--
?php extension_loaded('reflection') or die('skip'); ?
--FILE--
?php
class just_constants
{
const BOOLEAN_CONSTANT = true;
const NULL_CONSTANT = null;
const STRING_CONSTANT = 'This is a string';
const INTEGER_CONSTANT = 1000;
const FLOAT_CONSTANT = 3.14159265;
}

Reflection::export(new ReflectionClass('just_constants'));
?
--EXPECTF--
Class [ user class just_constants ] {
  @@ %s

  - Constants [5] {
Constant [ boolean BOOLEAN_CONSTANT ] { }
Constant [ null NULL_CONSTANT ] { }
Constant [ native string STRING_CONSTANT ] { }
Constant [ integer INTEGER_CONSTANT ] { }
Constant [ double FLOAT_CONSTANT ] { }
  }

  - Static properties [0] {
  }

  - Static methods [0] {
  }

  - Properties [0] {
  }

  - Methods [0] {
  }
}
--UEXPECTF--
Class [ user class just_constants ] {
  @@ %s

  - Constants [5] {
Constant [ boolean BOOLEAN_CONSTANT ] { }
Constant [ null NULL_CONSTANT ] { }
Constant [ Unicode string STRING_CONSTANT ] { }
Constant [ integer INTEGER_CONSTANT ] { }
Constant [ double FLOAT_CONSTANT ] { }
  }

  - Static properties [0] {
  }

  - Static methods [0] {
  }

  - Properties [0] {
  }

  - Methods [0] {
  }
}

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



[PHP-CVS] cvs: php-src(PHP_5_1) /ext/reflection php_reflection.c /ext/reflection/tests bug29986.phpt

2006-02-24 Thread Johannes Schl
johannesFri Feb 24 23:09:22 2006 UTC

  Added files: (Branch: PHP_5_1)
/php-src/ext/reflection/tests   bug29986.phpt 

  Modified files:  
/php-src/ext/reflection php_reflection.c 
  Log:
  - MFH: Fix #29986 (Class constants won't work with predefined constants when
using ReflectionClass)
  
http://cvs.php.net/viewcvs.cgi/php-src/ext/reflection/php_reflection.c?r1=1.164.2.25r2=1.164.2.26diff_format=u
Index: php-src/ext/reflection/php_reflection.c
diff -u php-src/ext/reflection/php_reflection.c:1.164.2.25 
php-src/ext/reflection/php_reflection.c:1.164.2.26
--- php-src/ext/reflection/php_reflection.c:1.164.2.25  Mon Feb 20 23:33:32 2006
+++ php-src/ext/reflection/php_reflection.c Fri Feb 24 23:09:22 2006
@@ -20,7 +20,7 @@
+--+
 */
 
-/* $Id: php_reflection.c,v 1.164.2.25 2006/02/20 23:33:32 johannes Exp $ */
+/* $Id: php_reflection.c,v 1.164.2.26 2006/02/24 23:09:22 johannes Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -352,6 +352,7 @@
 
/* Constants */
if (ce-constants_table) {
+   zend_hash_apply_with_argument(ce-constants_table, 
(apply_func_arg_t) zval_update_constant, (void*)1 TSRMLS_CC);
string_printf(str, \n);
count = zend_hash_num_elements(ce-constants_table);
string_printf(str, %s  - Constants [%d] {\n, indent, count);
@@ -4329,7 +4330,7 @@
php_info_print_table_start();
php_info_print_table_header(2, Reflection, enabled);
 
-   php_info_print_table_row(2, Version, $Id: php_reflection.c,v 
1.164.2.25 2006/02/20 23:33:32 johannes Exp $);
+   php_info_print_table_row(2, Version, $Id: php_reflection.c,v 
1.164.2.26 2006/02/24 23:09:22 johannes Exp $);
 
php_info_print_table_end();
 } /* }}} */

http://cvs.php.net/viewcvs.cgi/php-src/ext/reflection/tests/bug29986.phpt?view=markuprev=1.1
Index: php-src/ext/reflection/tests/bug29986.phpt
+++ php-src/ext/reflection/tests/bug29986.phpt
--TEST--
Reflection::export
--SKIPIF--
?php extension_loaded('reflection') or die('skip'); ?
--FILE--
?php
class just_constants
{
const BOOLEAN_CONSTANT = true;
const NULL_CONSTANT = null;
const STRING_CONSTANT = 'This is a string';
const INTEGER_CONSTANT = 1000;
const FLOAT_CONSTANT = 3.14159265;
}

Reflection::export(new ReflectionClass('just_constants'));
?
--EXPECTF--
Class [ user class just_constants ] {
  @@ %s

  - Constants [5] {
Constant [ boolean BOOLEAN_CONSTANT ] { }
Constant [ null NULL_CONSTANT ] { }
Constant [ native string STRING_CONSTANT ] { }
Constant [ integer INTEGER_CONSTANT ] { }
Constant [ double FLOAT_CONSTANT ] { }
  }

  - Static properties [0] {
  }

  - Static methods [0] {
  }

  - Properties [0] {
  }

  - Methods [0] {
  }
}
--UEXPECTF--
Class [ user class just_constants ] {
  @@ %s

  - Constants [5] {
Constant [ boolean BOOLEAN_CONSTANT ] { }
Constant [ null NULL_CONSTANT ] { }
Constant [ Unicode string STRING_CONSTANT ] { }
Constant [ integer INTEGER_CONSTANT ] { }
Constant [ double FLOAT_CONSTANT ] { }
  }

  - Static properties [0] {
  }

  - Static methods [0] {
  }

  - Properties [0] {
  }

  - Methods [0] {
  }
}

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



[PHP-CVS] cvs: php-src /ext/reflection php_reflection.c

2006-02-24 Thread Johannes Schl
johannesFri Feb 24 23:10:53 2006 UTC

  Modified files:  
/php-src/ext/reflection php_reflection.c 
  Log:
  - We need %v here
  
http://cvs.php.net/viewcvs.cgi/php-src/ext/reflection/php_reflection.c?r1=1.222r2=1.223diff_format=u
Index: php-src/ext/reflection/php_reflection.c
diff -u php-src/ext/reflection/php_reflection.c:1.222 
php-src/ext/reflection/php_reflection.c:1.223
--- php-src/ext/reflection/php_reflection.c:1.222   Fri Feb 24 23:08:36 2006
+++ php-src/ext/reflection/php_reflection.c Fri Feb 24 23:10:53 2006
@@ -20,7 +20,7 @@
+--+
 */
 
-/* $Id: php_reflection.c,v 1.222 2006/02/24 23:08:36 johannes Exp $ */
+/* $Id: php_reflection.c,v 1.223 2006/02/24 23:10:53 johannes Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -533,7 +533,7 @@
 /* {{{ _const_string */
 static void _const_string(string *str, char *name, zval *value, char *indent 
TSRMLS_DC)
 {
-   string_printf(str, %sConstant [ %s %s ] { }\n,
+   string_printf(str, %sConstant [ %s %v ] { }\n,
   indent,
   zend_zval_type_name(value),
   name);
@@ -4500,7 +4500,7 @@
php_info_print_table_start();
php_info_print_table_header(2, Reflection, enabled);
 
-   php_info_print_table_row(2, Version, $Id: php_reflection.c,v 1.222 
2006/02/24 23:08:36 johannes Exp $);
+   php_info_print_table_row(2, Version, $Id: php_reflection.c,v 1.223 
2006/02/24 23:10:53 johannes Exp $);
 
php_info_print_table_end();
 } /* }}} */

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



[PHP-CVS] cvs: php-src /ext/reflection/tests bug29986.phpt

2006-02-24 Thread Johannes Schl
johannesFri Feb 24 23:25:39 2006 UTC

  Modified files:  
/php-src/ext/reflection/tests   bug29986.phpt 
  Log:
  - Fix description
  
http://cvs.php.net/viewcvs.cgi/php-src/ext/reflection/tests/bug29986.phpt?r1=1.1r2=1.2diff_format=u
Index: php-src/ext/reflection/tests/bug29986.phpt
diff -u php-src/ext/reflection/tests/bug29986.phpt:1.1 
php-src/ext/reflection/tests/bug29986.phpt:1.2
--- php-src/ext/reflection/tests/bug29986.phpt:1.1  Fri Feb 24 23:08:36 2006
+++ php-src/ext/reflection/tests/bug29986.phpt  Fri Feb 24 23:25:39 2006
@@ -1,5 +1,5 @@
 --TEST--
-Reflection::export
+Bug #29986 (Class constants won't work with predefined constants when using 
ReflectionClass)
 --SKIPIF--
 ?php extension_loaded('reflection') or die('skip'); ?
 --FILE--

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



[PHP-CVS] cvs: php-src(PHP_5_1) /ext/reflection/tests bug29986.phpt

2006-02-24 Thread Johannes Schl
johannesFri Feb 24 23:25:57 2006 UTC

  Modified files:  (Branch: PHP_5_1)
/php-src/ext/reflection/tests   bug29986.phpt 
  Log:
  - MFH: Fix description
  
http://cvs.php.net/viewcvs.cgi/php-src/ext/reflection/tests/bug29986.phpt?r1=1.1.2.2r2=1.1.2.3diff_format=u
Index: php-src/ext/reflection/tests/bug29986.phpt
diff -u php-src/ext/reflection/tests/bug29986.phpt:1.1.2.2 
php-src/ext/reflection/tests/bug29986.phpt:1.1.2.3
--- php-src/ext/reflection/tests/bug29986.phpt:1.1.2.2  Fri Feb 24 23:09:22 2006
+++ php-src/ext/reflection/tests/bug29986.phpt  Fri Feb 24 23:25:57 2006
@@ -1,5 +1,5 @@
 --TEST--
-Reflection::export
+Bug #29986 Class constants won't work with predefined constants when using 
ReflectionClass
 --SKIPIF--
 ?php extension_loaded('reflection') or die('skip'); ?
 --FILE--

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



[PHP-CVS] cvs: php-src(PHP_5_1) /ext/reflection/tests bug26695.phpt bug29268.phpt

2006-02-26 Thread Johannes Schl
johannesMon Feb 27 00:18:59 2006 UTC

  Modified files:  (Branch: PHP_5_1)
/php-src/ext/reflection/tests   bug26695.phpt bug29268.phpt 
  Log:
  - Fix tests
  
http://cvs.php.net/viewcvs.cgi/php-src/ext/reflection/tests/bug26695.phpt?r1=1.2r2=1.2.4.1diff_format=u
Index: php-src/ext/reflection/tests/bug26695.phpt
diff -u php-src/ext/reflection/tests/bug26695.phpt:1.2 
php-src/ext/reflection/tests/bug26695.phpt:1.2.4.1
--- php-src/ext/reflection/tests/bug26695.phpt:1.2  Tue Mar 30 21:13:05 2004
+++ php-src/ext/reflection/tests/bug26695.phpt  Mon Feb 27 00:18:59 2006
@@ -15,7 +15,7 @@
 $methods = $class-getMethods();
 $params = $methods[0]-getParameters();
 
-$class = $params[0]-getClass();
+$class = $params[0]-getDeclaringClass();
 
 var_dump($class-getName());
 ?
http://cvs.php.net/viewcvs.cgi/php-src/ext/reflection/tests/bug29268.phpt?r1=1.1.2.1r2=1.1.2.2diff_format=u
Index: php-src/ext/reflection/tests/bug29268.phpt
diff -u php-src/ext/reflection/tests/bug29268.phpt:1.1.2.1 
php-src/ext/reflection/tests/bug29268.phpt:1.1.2.2
--- php-src/ext/reflection/tests/bug29268.phpt:1.1.2.1  Fri Oct 21 08:03:28 2005
+++ php-src/ext/reflection/tests/bug29268.phpt  Mon Feb 27 00:18:59 2006
@@ -15,7 +15,7 @@
 $ref = new reflectionMethod('B','doit');
 $parameters = $ref-getParameters();   
 foreach($parameters as $parameter){
-   $class = $parameter-getClass();
+   $class = $parameter-getDeclaringClass();   
echo $class-name.\n;
 }
 echo ok\n;

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



[PHP-CVS] cvs: php-src /ext/hash/tests .cvsignore

2006-02-27 Thread Johannes Schl
johannesMon Feb 27 11:37:03 2006 UTC

  Added files: 
/php-src/ext/hash/tests .cvsignore 
  Log:
  - Add .cvsignore
  

http://cvs.php.net/viewcvs.cgi/php-src/ext/hash/tests/.cvsignore?view=markuprev=1.1
Index: php-src/ext/hash/tests/.cvsignore
+++ php-src/ext/hash/tests/.cvsignore
phpt.*
*.diff
*.log
*.exp
*.out
*.php
*.gcda
*.gcno

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



[PHP-CVS] cvs: php-src(PHP_5_1) /ext/hash/tests .cvsignore

2006-02-27 Thread Johannes Schl
johannesMon Feb 27 11:38:36 2006 UTC

  Added files: (Branch: PHP_5_1)
/php-src/ext/hash/tests .cvsignore 
  Log:
  - MFH: Add .cvsignore
  

http://cvs.php.net/viewcvs.cgi/php-src/ext/hash/tests/.cvsignore?view=markuprev=1.1
Index: php-src/ext/hash/tests/.cvsignore
+++ php-src/ext/hash/tests/.cvsignore
phpt.*
*.diff
*.log
*.exp
*.out
*.php
*.gcda
*.gcno

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



[PHP-CVS] cvs: php-src /sapi/cli php_cli.c php_cli_readline.c

2005-05-17 Thread Johannes Schl
johannesTue May 17 10:33:15 2005 EDT

  Modified files:  
/php-src/sapi/cli   php_cli.c php_cli_readline.c 
  Log:
  - Fix readline loop-condition
  - Fix cli_is_valid_code detection
  
http://cvs.php.net/diff.php/php-src/sapi/cli/php_cli.c?r1=1.124r2=1.125ty=u
Index: php-src/sapi/cli/php_cli.c
diff -u php-src/sapi/cli/php_cli.c:1.124 php-src/sapi/cli/php_cli.c:1.125
--- php-src/sapi/cli/php_cli.c:1.124Sat May 14 15:33:18 2005
+++ php-src/sapi/cli/php_cli.c  Tue May 17 10:33:15 2005
@@ -20,7 +20,7 @@
+--+
 */
 
-/* $Id: php_cli.c,v 1.124 2005/05/14 19:33:18 helly Exp $ */
+/* $Id: php_cli.c,v 1.125 2005/05/17 14:33:15 johannes Exp $ */
 
 #include php.h
 #include php_globals.h
@@ -978,12 +978,11 @@
 
history_file = tilde_expand(~/.php_history);
rl_attempted_completion_function = 
cli_code_completion;
-   /*rl_completion_append_character = '(';*/
rl_special_prefixes = $;
read_history(history_file);
 
EG(exit_status) = 0;
-   while ((line = readline(pos ? prompt : php  
)) != NULL) {
+   while ((line = readline(prompt)) != NULL) {
if (strcmp(line, exit) == 0 || 
strcmp(line, quit) == 0) {
free(line);
break;
http://cvs.php.net/diff.php/php-src/sapi/cli/php_cli_readline.c?r1=1.1r2=1.2ty=u
Index: php-src/sapi/cli/php_cli_readline.c
diff -u php-src/sapi/cli/php_cli_readline.c:1.1 
php-src/sapi/cli/php_cli_readline.c:1.2
--- php-src/sapi/cli/php_cli_readline.c:1.1 Sat May 14 15:33:18 2005
+++ php-src/sapi/cli/php_cli_readline.c Tue May 17 10:33:15 2005
@@ -17,7 +17,7 @@
+--+
 */
 
-/* $Id: php_cli_readline.c,v 1.1 2005/05/14 19:33:18 helly Exp $ */
+/* $Id: php_cli_readline.c,v 1.2 2005/05/17 14:33:15 johannes Exp $ */
 
 #include php.h
 #include php_globals.h
@@ -73,7 +73,7 @@
 
 int cli_is_valid_code(char *code, int len, char **prompt TSRMLS_DC)
 {
-   int valid_end = 1;
+   int valid_end = 1, last_valid_end;
int brackets_count = 0;
int brace_count = 0;
int i;
@@ -109,6 +109,7 @@
valid_end = brace_count == 0  
brackets_count == 0;
break;
case ' ':
+   case '\r':
case '\n':
case '\t':
break;
@@ -118,6 +119,9 @@
case '':
code_type = dstring;
break;
+   case '#':
+   code_type = comment_line;
+   break;
case '/':
if (code[i+1] == '/') {
i++;
@@ -125,6 +129,8 @@
break;
}
if (code[i+1] == '*') {
+   last_valid_end = 
valid_end;
+   valid_end = 0;
code_type = 
comment_block;
i++;
break;
@@ -190,6 +196,7 @@
case comment_block:
if (code[i-1] == '*'  code[i] == '/') {
code_type = body;
+   valid_end = last_valid_end;
}
break;
case heredoc_start:

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



[PHP-CVS] cvs: php-src /ext/spl/internal fileobject.inc

2005-06-16 Thread Johannes Schl
johannesThu Jun 16 17:27:51 2005 EDT

  Modified files:  
/php-src/ext/spl/internal   fileobject.inc 
  Log:
  fix typos
  
http://cvs.php.net/diff.php/php-src/ext/spl/internal/fileobject.inc?r1=1.4r2=1.5ty=u
Index: php-src/ext/spl/internal/fileobject.inc
diff -u php-src/ext/spl/internal/fileobject.inc:1.4 
php-src/ext/spl/internal/fileobject.inc:1.5
--- php-src/ext/spl/internal/fileobject.inc:1.4 Mon May 30 16:10:38 2005
+++ php-src/ext/spl/internal/fileobject.inc Thu Jun 16 17:27:51 2005
@@ -31,9 +31,9 @@
 * @param $open_mode The file open mode
 * @param $use_include_path  Whether to search in include paths
 * @param $context   A stream context
-* @throw RuntimeException   If file cannot be opened (e.g. 
insufficient 
-*   access rights).
-*/
+* @throw RuntimeException   If file cannot be opened (e.g. 
insufficient 
+*   access rights).
+*/
function __construct($file_name, $open_mode = 'r', $use_include_path = 
false, $context = NULL)
{
$this-fp = fopen($file_name, $open_mode, $use_include_path, 
$context);
@@ -53,7 +53,7 @@
}
 
/**
-* @return whethe rend of stream is reached
+* @return whether the end of the stream is reached
 */
function eof()
{
@@ -85,7 +85,7 @@
}
 
/**
-* @param operation lock opeation (LOCK_SH, LOCK_EX, LOCK_UN, LOCK_NB)
+* @param operation lock operation (LOCK_SH, LOCK_EX, LOCK_UN, LOCK_NB)
 * @retval $wouldblock  whether the operation would block
 */
function flock($operation, $wouldblock)
@@ -210,7 +210,7 @@
}
 
/**
-* @return curren tsetting for max line
+* @return current setting for max line
 */
function getMaxLineLen()
{

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



[PHP-CVS] cvs: php-src /ext/standard php_incomplete_class.h

2005-06-29 Thread Johannes Schl
johannesWed Jun 29 05:28:44 2005 EDT

  Modified files:  
/php-src/ext/standard   php_incomplete_class.h 
  Log:
  - Fix TSRM build
  
http://cvs.php.net/diff.php/php-src/ext/standard/php_incomplete_class.h?r1=1.14r2=1.15ty=u
Index: php-src/ext/standard/php_incomplete_class.h
diff -u php-src/ext/standard/php_incomplete_class.h:1.14 
php-src/ext/standard/php_incomplete_class.h:1.15
--- php-src/ext/standard/php_incomplete_class.h:1.14Tue Jun 28 05:46:30 2005
+++ php-src/ext/standard/php_incomplete_class.h Wed Jun 29 05:28:44 2005
@@ -16,7 +16,7 @@
+--+
 */
 
-/* $Id: php_incomplete_class.h,v 1.14 2005/06/28 09:46:30 stas Exp $ */
+/* $Id: php_incomplete_class.h,v 1.15 2005/06/29 09:28:44 johannes Exp $ */
 
 #ifndef PHP_INCOMPLETE_CLASS_H
 #define PHP_INCOMPLETE_CLASS_H
@@ -34,7 +34,7 @@
free_class_name = 1; \
incomplete_class = 1; \
} else { \
-   free_class_name = !zend_get_object_classname(struc, 
class_name, name_len);\
+   free_class_name = !zend_get_object_classname(struc, 
class_name, name_len TSRMLS_CC);\
}
 
 #define PHP_CLEANUP_CLASS_ATTRIBUTES() \

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



[PHP-CVS] cvs: php-src(PHP_5_0) /ext/standard php_incomplete_class.h

2005-06-29 Thread Johannes Schl
johannesWed Jun 29 05:29:08 2005 EDT

  Modified files:  (Branch: PHP_5_0)
/php-src/ext/standard   php_incomplete_class.h 
  Log:
  - MFH: Fix TSRM build
  
http://cvs.php.net/diff.php/php-src/ext/standard/php_incomplete_class.h?r1=1.13.2.1r2=1.13.2.2ty=u
Index: php-src/ext/standard/php_incomplete_class.h
diff -u php-src/ext/standard/php_incomplete_class.h:1.13.2.1 
php-src/ext/standard/php_incomplete_class.h:1.13.2.2
--- php-src/ext/standard/php_incomplete_class.h:1.13.2.1Tue Jun 28 
05:17:19 2005
+++ php-src/ext/standard/php_incomplete_class.h Wed Jun 29 05:29:08 2005
@@ -16,7 +16,7 @@
+--+
 */
 
-/* $Id: php_incomplete_class.h,v 1.13.2.1 2005/06/28 09:17:19 stas Exp $ */
+/* $Id: php_incomplete_class.h,v 1.13.2.2 2005/06/29 09:29:08 johannes Exp $ */
 
 #ifndef PHP_INCOMPLETE_CLASS_H
 #define PHP_INCOMPLETE_CLASS_H
@@ -34,7 +34,7 @@
free_class_name = 1; \
incomplete_class = 1; \
} else { \
-   free_class_name = !zend_get_object_classname(struc, 
class_name, name_len);\
+   free_class_name = !zend_get_object_classname(struc, 
class_name, name_len TSRMLS_CC);\
}
 
 #define PHP_CLEANUP_CLASS_ATTRIBUTES() \

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



[PHP-CVS] cvs: php-src /ext/spl spl_iterators.c

2006-11-07 Thread Johannes Schl
johannesTue Nov  7 15:17:42 2006 UTC

  Modified files:  
/php-src/ext/splspl_iterators.c 
  Log:
  - No C++ comments (fix #39414)
  
http://cvs.php.net/viewvc.cgi/php-src/ext/spl/spl_iterators.c?r1=1.153r2=1.154diff_format=u
Index: php-src/ext/spl/spl_iterators.c
diff -u php-src/ext/spl/spl_iterators.c:1.153 
php-src/ext/spl/spl_iterators.c:1.154
--- php-src/ext/spl/spl_iterators.c:1.153   Mon Nov  6 23:19:46 2006
+++ php-src/ext/spl/spl_iterators.c Tue Nov  7 15:17:42 2006
@@ -16,7 +16,7 @@
+--+
  */
 
-/* $Id: spl_iterators.c,v 1.153 2006/11/06 23:19:46 bjori Exp $ */
+/* $Id: spl_iterators.c,v 1.154 2006/11/07 15:17:42 johannes Exp $ */
 
 #ifdef HAVE_CONFIG_H
 # include config.h
@@ -1512,7 +1512,7 @@
 
if (mode  0 || mode = REGIT_MODE_MAX) {
zend_throw_exception_ex(spl_ce_InvalidArgumentException, 0 
TSRMLS_CC, Illegal mode %ld, mode);
-   return;// NULL
+   return;/* NULL */
}
 
intern-u.regex.mode = mode;

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



[PHP-CVS] cvs: php-src(PHP_5_2) / NEWS /ext/spl spl_iterators.c

2006-11-07 Thread Johannes Schl
johannesTue Nov  7 15:19:11 2006 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/ext/splspl_iterators.c 
/php-srcNEWS 
  Log:
  - MFH: No C++ comments (fix #39414)
  
http://cvs.php.net/viewvc.cgi/php-src/ext/spl/spl_iterators.c?r1=1.73.2.30.2.19r2=1.73.2.30.2.20diff_format=u
Index: php-src/ext/spl/spl_iterators.c
diff -u php-src/ext/spl/spl_iterators.c:1.73.2.30.2.19 
php-src/ext/spl/spl_iterators.c:1.73.2.30.2.20
--- php-src/ext/spl/spl_iterators.c:1.73.2.30.2.19  Mon Nov  6 23:20:11 2006
+++ php-src/ext/spl/spl_iterators.c Tue Nov  7 15:19:11 2006
@@ -16,7 +16,7 @@
+--+
  */
 
-/* $Id: spl_iterators.c,v 1.73.2.30.2.19 2006/11/06 23:20:11 bjori Exp $ */
+/* $Id: spl_iterators.c,v 1.73.2.30.2.20 2006/11/07 15:19:11 johannes Exp $ */
 
 #ifdef HAVE_CONFIG_H
 # include config.h
@@ -1487,7 +1487,7 @@
 
if (mode  0 || mode = REGIT_MODE_MAX) {
zend_throw_exception_ex(spl_ce_InvalidArgumentException, 0 
TSRMLS_CC, Illegal mode %ld, mode);
-   return;// NULL
+   return;/* NULL */
}
 
intern-u.regex.mode = mode;
http://cvs.php.net/viewvc.cgi/php-src/NEWS?r1=1.2027.2.547.2.334r2=1.2027.2.547.2.335diff_format=u
Index: php-src/NEWS
diff -u php-src/NEWS:1.2027.2.547.2.334 php-src/NEWS:1.2027.2.547.2.335
--- php-src/NEWS:1.2027.2.547.2.334 Mon Nov  6 17:21:05 2006
+++ php-src/NEWSTue Nov  7 15:19:11 2006
@@ -13,6 +13,8 @@
 php_filter.h).
 - Fixed wrong signature initialization in imagepng (Takeshi Abe)
 - Added optimization for imageline with horizontal and vertial lines (Pierre)
+- Fixed bug #39414 (Syntax error while compiling with Sun Workshop Complier).
+  (Johannes)
 - Fixed bug #39366 (imagerotate does not use alpha with angle  45°) (Pierre)
 - Fixed bug #39362 (Added an option to imap_open/imap_reopen to control the 
   number of connection retries). (Ilia)

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



[PHP-CVS] cvs: php-src /sapi/cli php.1.in

2007-01-10 Thread Johannes Schl
johannesWed Jan 10 22:17:09 2007 UTC

  Modified files:  
/php-src/sapi/cli   php.1.in 
  Log:
  - Bump year
  
http://cvs.php.net/viewvc.cgi/php-src/sapi/cli/php.1.in?r1=1.15r2=1.16diff_format=u
Index: php-src/sapi/cli/php.1.in
diff -u php-src/sapi/cli/php.1.in:1.15 php-src/sapi/cli/php.1.in:1.16
--- php-src/sapi/cli/php.1.in:1.15  Sun Apr 23 19:57:40 2006
+++ php-src/sapi/cli/php.1.in   Wed Jan 10 22:17:09 2007
@@ -1,4 +1,4 @@
-.TH PHP 1 2006 The PHP Group Scripting Language
+.TH PHP 1 2007 The PHP Group Scripting Language
 .SH NAME
 .TP 15
 php \- PHP Command Line Interface 'CLI'
@@ -390,7 +390,7 @@
 .SH VERSION INFORMATION
 This manpage describes \fBphp\fP, version @[EMAIL PROTECTED]
 .SH COPYRIGHT
-Copyright \(co 1997\-2006 The PHP Group
+Copyright \(co 1997\-2007 The PHP Group
 .LP
 This source file is subject to version 3.01 of the PHP license,
 that is bundled with this package in the file LICENSE, and is

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



[PHP-CVS] cvs: php-src(PHP_5_2) /sapi/cli php.1.in

2007-01-10 Thread Johannes Schl
johannesWed Jan 10 22:17:27 2007 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/sapi/cli   php.1.in 
  Log:
  - MFH: Bump year
  
http://cvs.php.net/viewvc.cgi/php-src/sapi/cli/php.1.in?r1=1.12.2.3r2=1.12.2.3.2.1diff_format=u
Index: php-src/sapi/cli/php.1.in
diff -u php-src/sapi/cli/php.1.in:1.12.2.3 
php-src/sapi/cli/php.1.in:1.12.2.3.2.1
--- php-src/sapi/cli/php.1.in:1.12.2.3  Sun Apr 23 19:56:53 2006
+++ php-src/sapi/cli/php.1.in   Wed Jan 10 22:17:27 2007
@@ -1,4 +1,4 @@
-.TH PHP 1 2006 The PHP Group Scripting Language
+.TH PHP 1 2007 The PHP Group Scripting Language
 .SH NAME
 .TP 15
 php \- PHP Command Line Interface 'CLI'
@@ -390,7 +390,7 @@
 .SH VERSION INFORMATION
 This manpage describes \fBphp\fP, version @[EMAIL PROTECTED]
 .SH COPYRIGHT
-Copyright \(co 1997\-2006 The PHP Group
+Copyright \(co 1997\-2007 The PHP Group
 .LP
 This source file is subject to version 3.01 of the PHP license,
 that is bundled with this package in the file LICENSE, and is

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



[PHP-CVS] cvs: php-src(PHP_4_4) /sapi/cli php.1.in

2007-01-10 Thread Johannes Schl
johannesWed Jan 10 22:17:41 2007 UTC

  Modified files:  (Branch: PHP_4_4)
/php-src/sapi/cli   php.1.in 
  Log:
  - MFH: Bump year
  
http://cvs.php.net/viewvc.cgi/php-src/sapi/cli/php.1.in?r1=1.1.2.4.2.2r2=1.1.2.4.2.3diff_format=u
Index: php-src/sapi/cli/php.1.in
diff -u php-src/sapi/cli/php.1.in:1.1.2.4.2.2 
php-src/sapi/cli/php.1.in:1.1.2.4.2.3
--- php-src/sapi/cli/php.1.in:1.1.2.4.2.2   Wed Jul 26 16:25:58 2006
+++ php-src/sapi/cli/php.1.in   Wed Jan 10 22:17:41 2007
@@ -1,4 +1,4 @@
-.TH PHP 1 2006 The PHP Group Scripting Language
+.TH PHP 1 2007 The PHP Group Scripting Language
 .SH NAME
 .TP 15
 php - PHP Command Line Interface 'CLI'
@@ -185,7 +185,7 @@
 .SH VERSION INFORMATION
 This manpage describes \fBphp\fP, version @[EMAIL PROTECTED]
 .SH COPYRIGHT
-Copyright \(co 1997\-2006 The PHP Group
+Copyright \(co 1997\-2007 The PHP Group
 .LP
 This source file is subject to version 3.01 of the PHP license,
 that is bundled with this package in the file LICENSE, and is

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



[PHP-CVS] cvs: php-src /ext/standard info.c

2007-01-23 Thread Johannes Schl
johannesTue Jan 23 15:47:28 2007 UTC

  Modified files:  
/php-src/ext/standard   info.c 
  Log:
  - Use utf-8 instead of utf8 as encoding to fix phpinfo()
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/info.c?r1=1.274r2=1.275diff_format=u
Index: php-src/ext/standard/info.c
diff -u php-src/ext/standard/info.c:1.274 php-src/ext/standard/info.c:1.275
--- php-src/ext/standard/info.c:1.274   Mon Jan  1 09:29:32 2007
+++ php-src/ext/standard/info.c Tue Jan 23 15:47:28 2007
@@ -18,7 +18,7 @@
+--+
 */
 
-/* $Id: info.c,v 1.274 2007/01/01 09:29:32 sebastian Exp $ */
+/* $Id: info.c,v 1.275 2007/01/23 15:47:28 johannes Exp $ */
 
 #include php.h
 #include php_ini.h
@@ -67,7 +67,7 @@
char *new_str;
TSRMLS_FETCH();

-   new_str = php_escape_html_entities((char *) str, len, new_len, 0, 
ENT_QUOTES, utf8 TSRMLS_CC);
+   new_str = php_escape_html_entities((char *) str, len, new_len, 0, 
ENT_QUOTES, utf-8 TSRMLS_CC);
written = php_output_write_utf8(new_str, new_len TSRMLS_CC);
efree(new_str);
return written;

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



[PHP-CVS] cvs: php-src /main output.c /tests/output ob_020.phpt

2007-03-03 Thread Johannes Schl
johannesSat Mar  3 10:27:04 2007 UTC

  Modified files:  
/php-src/main   output.c 
/php-src/tests/output   ob_020.phpt 
  Log:
  - Fix old behaviour, ob_list_handlers() should always return an array
  
http://cvs.php.net/viewvc.cgi/php-src/main/output.c?r1=1.205r2=1.206diff_format=u
Index: php-src/main/output.c
diff -u php-src/main/output.c:1.205 php-src/main/output.c:1.206
--- php-src/main/output.c:1.205 Mon Jan 29 13:04:57 2007
+++ php-src/main/output.c   Sat Mar  3 10:27:04 2007
@@ -19,7 +19,7 @@
+--+
 */
 
-/* $Id: output.c,v 1.205 2007/01/29 13:04:57 mike Exp $ */
+/* $Id: output.c,v 1.206 2007/03/03 10:27:04 johannes Exp $ */
 
 #ifndef PHP_OUTPUT_DEBUG
 #  define PHP_OUTPUT_DEBUG 0
@@ -1504,11 +1504,13 @@
if (ZEND_NUM_ARGS()) {
ZEND_WRONG_PARAM_COUNT();
}
+
+   array_init(return_value);
+
if (!OG(active)) {
-   RETURN_FALSE;
+   return;
}

-   array_init(return_value);
zend_stack_apply_with_argument(OG(handlers), ZEND_STACK_APPLY_BOTTOMUP, 
php_output_stack_apply_list, return_value);
 }
 /* }}} */
http://cvs.php.net/viewvc.cgi/php-src/tests/output/ob_020.phpt?r1=1.3r2=1.4diff_format=u
Index: php-src/tests/output/ob_020.phpt
diff -u /dev/null php-src/tests/output/ob_020.phpt:1.4
--- /dev/null   Sat Mar  3 10:27:04 2007
+++ php-src/tests/output/ob_020.phptSat Mar  3 10:27:04 2007
@@ -0,0 +1,38 @@
+--TEST--
+output buffering - ob_list_handlers
+--FILE--
+?php
+print_r(ob_list_handlers());
+
+ob_start();
+print_r(ob_list_handlers());
+
+ob_start();
+print_r(ob_list_handlers());
+
+ob_end_flush();
+print_r(ob_list_handlers());
+
+ob_end_flush();
+print_r(ob_list_handlers());
+?
+--EXPECT--
+Array
+(
+)
+Array
+(
+[0] = default output handler
+)
+Array
+(
+[0] = default output handler
+[1] = default output handler
+)
+Array
+(
+[0] = default output handler
+)
+Array
+(
+)

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



[PHP-CVS] cvs: php-src /ext/reflection php_reflection.c /ext/reflection/tests bug39884.phpt

2007-03-17 Thread Johannes Schl
johannesSat Mar 17 23:38:41 2007 UTC

  Modified files:  
/php-src/ext/reflection php_reflection.c 
/php-src/ext/reflection/tests   bug39884.phpt 
  Log:
  - Fix string compare in unicode mode
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/reflection/php_reflection.c?r1=1.273r2=1.274diff_format=u
Index: php-src/ext/reflection/php_reflection.c
diff -u php-src/ext/reflection/php_reflection.c:1.273 
php-src/ext/reflection/php_reflection.c:1.274
--- php-src/ext/reflection/php_reflection.c:1.273   Sat Mar 17 22:59:22 2007
+++ php-src/ext/reflection/php_reflection.c Sat Mar 17 23:38:41 2007
@@ -20,7 +20,7 @@
+--+
 */
 
-/* $Id: php_reflection.c,v 1.273 2007/03/17 22:59:22 tony2001 Exp $ */
+/* $Id: php_reflection.c,v 1.274 2007/03/17 23:38:41 johannes Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -2027,7 +2027,7 @@
 * TODO: Think about moving these checks to the compiler or 
some sort of
 * lint-mode.
 */
-   if (0 == strncmp(param-arg_info-class_name.v, self, 
sizeof(self)- 1)) {
+   if (ZEND_U_EQUAL(ZEND_STR_TYPE, param-arg_info-class_name, 
param-arg_info-class_name_len, self, sizeof(self)- 1)) {
zend_class_entry *ce= param-fptr-common.scope;
if (!ce) {
   zend_throw_exception_ex(reflection_exception_ptr, 0 
TSRMLS_CC, 
@@ -2035,7 +2035,7 @@
   return;
}
pce= ce;
-   } else if (0 == strncmp(param-arg_info-class_name.v, 
parent, sizeof(parent)- 1)) {
+   } else if (ZEND_U_EQUAL(ZEND_STR_TYPE, 
param-arg_info-class_name,  param-arg_info-class_name_len, parent, 
sizeof(parent)- 1)) {
zend_class_entry *ce= param-fptr-common.scope;
if (!ce) {
   zend_throw_exception_ex(reflection_exception_ptr, 0 
TSRMLS_CC, 
@@ -4987,7 +4987,7 @@
php_info_print_table_start();
php_info_print_table_header(2, Reflection, enabled);
 
-   php_info_print_table_row(2, Version, $Id: php_reflection.c,v 1.273 
2007/03/17 22:59:22 tony2001 Exp $);
+   php_info_print_table_row(2, Version, $Id: php_reflection.c,v 1.274 
2007/03/17 23:38:41 johannes Exp $);
 
php_info_print_table_end();
 } /* }}} */
http://cvs.php.net/viewvc.cgi/php-src/ext/reflection/tests/bug39884.phpt?r1=1.2r2=1.3diff_format=u
Index: php-src/ext/reflection/tests/bug39884.phpt
diff -u php-src/ext/reflection/tests/bug39884.phpt:1.2 
php-src/ext/reflection/tests/bug39884.phpt:1.3
--- php-src/ext/reflection/tests/bug39884.phpt:1.2  Fri Dec 22 15:38:42 2006
+++ php-src/ext/reflection/tests/bug39884.phpt  Sat Mar 17 23:38:41 2007
@@ -20,3 +20,9 @@
   [name]=
   string(13) stubParamTest
 }
+--UEXPECT--
+object(ReflectionClass)#4 (1) {
+  [uname]=
+  unicode(13) stubParamTest
+}
+

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



[PHP-CVS] cvs: php-src /sapi/cli getopt.c /sapi/cli/tests 015.phpt

2007-03-22 Thread Johannes Schl
johannesThu Mar 22 21:34:58 2007 UTC

  Added files: 
/php-src/sapi/cli/tests 015.phpt 

  Modified files:  
/php-src/sapi/cli   getopt.c 
  Log:
  - Fix handling of not existing long CLI options
  
http://cvs.php.net/viewvc.cgi/php-src/sapi/cli/getopt.c?r1=1.11r2=1.12diff_format=u
Index: php-src/sapi/cli/getopt.c
diff -u php-src/sapi/cli/getopt.c:1.11 php-src/sapi/cli/getopt.c:1.12
--- php-src/sapi/cli/getopt.c:1.11  Wed Mar 21 23:19:00 2007
+++ php-src/sapi/cli/getopt.c   Thu Mar 22 21:34:58 2007
@@ -16,7 +16,7 @@
+--+
 */
 
-/* $Id: getopt.c,v 1.11 2007/03/21 23:19:00 helly Exp $ */
+/* $Id: getopt.c,v 1.12 2007/03/22 21:34:58 johannes Exp $ */
 
 #include stdio.h
 #include string.h
@@ -79,11 +79,16 @@
}
if ((argv[*optind][0] == '-')  (argv[*optind][1] == '-')) {
/* '--' indicates end of args if not followed by a known long 
option name */
+   if (argv[*optind][2] == '\0') {
+   (*optind)++;
+   return(EOF);
+   }
+
while (1) {
opts_idx++;
if (opts[opts_idx].opt_char == '-') {
(*optind)++;
-   return(EOF);
+   return(php_opt_error(argc, argv, *optind-1, 
optchr, OPTERRARG, show_err));
} else if (opts[opts_idx].opt_name  
!strcmp(argv[*optind][2], opts[opts_idx].opt_name)) {
break;
}

http://cvs.php.net/viewvc.cgi/php-src/sapi/cli/tests/015.phpt?view=markuprev=1.1
Index: php-src/sapi/cli/tests/015.phpt
+++ php-src/sapi/cli/tests/015.phpt
--TEST--
CLI long options
--SKIPIF--
?php include skipif.inc; ?
--FILE--
?php

$php = getenv('TEST_PHP_EXECUTABLE');


echo `$php --version | grep built:`;
echo `echo ?php print_r(\\\$argv); | $php -- foo bar baz`, \n;
echo `$php --version foo bar baz | grep built:`;
echo `$php --notexisting foo bar baz | grep Usage:`;

echo Done\n;
?
--EXPECTF-- 
PHP %d.%d.%d%s(cli) (built: %s)
Array
(
[0] = -
[1] = foo
[2] = bar
[3] = baz
)

PHP %d.%d.%d%s(cli) (built: %s)
Usage: php [options] [-f] file [--] [args...]
Done

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



[PHP-CVS] cvs: php-src(PHP_5_2) /sapi/cli getopt.c /sapi/cli/tests 015.phpt

2007-03-22 Thread Johannes Schl
johannesThu Mar 22 21:35:41 2007 UTC

  Added files: (Branch: PHP_5_2)
/php-src/sapi/cli/tests 015.phpt 

  Modified files:  
/php-src/sapi/cli   getopt.c 
  Log:
  - MFH: Fix handling of not existing long CLI options
  
http://cvs.php.net/viewvc.cgi/php-src/sapi/cli/getopt.c?r1=1.8.2.1.2.2r2=1.8.2.1.2.3diff_format=u
Index: php-src/sapi/cli/getopt.c
diff -u php-src/sapi/cli/getopt.c:1.8.2.1.2.2 
php-src/sapi/cli/getopt.c:1.8.2.1.2.3
--- php-src/sapi/cli/getopt.c:1.8.2.1.2.2   Wed Mar 21 23:20:21 2007
+++ php-src/sapi/cli/getopt.c   Thu Mar 22 21:35:41 2007
@@ -16,7 +16,7 @@
+--+
 */
 
-/* $Id: getopt.c,v 1.8.2.1.2.2 2007/03/21 23:20:21 helly Exp $ */
+/* $Id: getopt.c,v 1.8.2.1.2.3 2007/03/22 21:35:41 johannes Exp $ */
 
 #include stdio.h
 #include string.h
@@ -79,11 +79,16 @@
}
if ((argv[*optind][0] == '-')  (argv[*optind][1] == '-')) {
/* '--' indicates end of args if not followed by a known long 
option name */
+   if (argv[*optind][2] == '\0') {
+   (*optind)++;
+   return(EOF);
+   }
+
while (1) {
opts_idx++;
if (opts[opts_idx].opt_char == '-') {
(*optind)++;
-   return(EOF);
+   return(php_opt_error(argc, argv, *optind-1, 
optchr, OPTERRARG, show_err));
} else if (opts[opts_idx].opt_name  
!strcmp(argv[*optind][2], opts[opts_idx].opt_name)) {
break;
}

http://cvs.php.net/viewvc.cgi/php-src/sapi/cli/tests/015.phpt?view=markuprev=1.1
Index: php-src/sapi/cli/tests/015.phpt
+++ php-src/sapi/cli/tests/015.phpt
--TEST--
CLI long options
--SKIPIF--
?php include skipif.inc; ?
--FILE--
?php

$php = getenv('TEST_PHP_EXECUTABLE');


echo `$php --version | grep built:`;
echo `echo ?php print_r(\\\$argv); | $php -- foo bar baz`, \n;
echo `$php --version foo bar baz | grep built:`;
echo `$php --notexisting foo bar baz | grep Usage:`;

echo Done\n;
?
--EXPECTF-- 
PHP %d.%d.%d%s(cli) (built: %s)
Array
(
[0] = -
[1] = foo
[2] = bar
[3] = baz
)

PHP %d.%d.%d%s(cli) (built: %s)
Usage: php [options] [-f] file [--] [args...]
Done

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



[PHP-CVS] cvs: php-src(PHP_4_4) /sapi/cli getopt.c

2007-03-22 Thread Johannes Schl
johannesThu Mar 22 21:35:56 2007 UTC

  Modified files:  (Branch: PHP_4_4)
/php-src/sapi/cli   getopt.c 
  Log:
  - MFH: Fix handling of not existing long CLI options
  
http://cvs.php.net/viewvc.cgi/php-src/sapi/cli/getopt.c?r1=1.3.4.3.6.3r2=1.3.4.3.6.4diff_format=u
Index: php-src/sapi/cli/getopt.c
diff -u php-src/sapi/cli/getopt.c:1.3.4.3.6.3 
php-src/sapi/cli/getopt.c:1.3.4.3.6.4
--- php-src/sapi/cli/getopt.c:1.3.4.3.6.3   Wed Mar 21 23:20:30 2007
+++ php-src/sapi/cli/getopt.c   Thu Mar 22 21:35:56 2007
@@ -16,7 +16,7 @@
+--+
 */
 
-/* $Id: getopt.c,v 1.3.4.3.6.3 2007/03/21 23:20:30 helly Exp $ */
+/* $Id: getopt.c,v 1.3.4.3.6.4 2007/03/22 21:35:56 johannes Exp $ */
 
 #include stdio.h
 #include string.h
@@ -79,11 +79,16 @@
}
if ((argv[*optind][0] == '-')  (argv[*optind][1] == '-')) {
/* '--' indicates end of args if not followed by a known long 
option name */
+   if (argv[*optind][2] == '\0') {
+   (*optind)++;
+   return(EOF);
+   }
+
while (1) {
opts_idx++;
if (opts[opts_idx].opt_char == '-') {
(*optind)++;
-   return(EOF);
+   return(php_opt_error(argc, argv, *optind-1, 
optchr, OPTERRARG, show_err));
} else if (opts[opts_idx].opt_name  
!strcmp(argv[*optind][2], opts[opts_idx].opt_name)) {
break;
}

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



[PHP-CVS] cvs: php-src /ext/tokenizer tokenizer.c /ext/tokenizer/tests 002.phpt 003.phpt bug26463.phpt

2007-04-07 Thread Johannes Schl
johannesSun Apr  8 00:17:40 2007 UTC

  Modified files:  
/php-src/ext/tokenizer  tokenizer.c 
/php-src/ext/tokenizer/tests002.phpt 003.phpt bug26463.phpt 
  Log:
  - Added linenumbers to array returned by token_get_all()
  
  http://cvs.php.net/viewvc.cgi/php-src/ext/tokenizer/tokenizer.c?r1=1.40r2=1.41diff_format=u
Index: php-src/ext/tokenizer/tokenizer.c
diff -u php-src/ext/tokenizer/tokenizer.c:1.40 
php-src/ext/tokenizer/tokenizer.c:1.41
--- php-src/ext/tokenizer/tokenizer.c:1.40  Fri Jan 12 12:16:36 2007
+++ php-src/ext/tokenizer/tokenizer.c   Sun Apr  8 00:17:40 2007
@@ -16,7 +16,7 @@
+--+
 */
 
-/* $Id: tokenizer.c,v 1.40 2007/01/12 12:16:36 tony2001 Exp $ */
+/* $Id: tokenizer.c,v 1.41 2007/04/08 00:17:40 johannes Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -272,6 +272,7 @@
zval *keyword;
int token_type;
zend_bool destroy;
+   int token_line = 1;
 
CG(literal_type) = UG(unicode)?IS_UNICODE:IS_STRING;
 
@@ -301,6 +302,7 @@
} else {
add_next_index_stringl(keyword, zendtext, 
zendleng, 1);
}
+   add_next_index_long(keyword, token_line);
add_next_index_zval(return_value, keyword);
} else {
add_next_index_stringl(return_value, zendtext, 
zendleng, 1);
@@ -309,6 +311,8 @@
zval_dtor(token);
}
ZVAL_NULL(token);
+
+   token_line = CG(zend_lineno);
}
 }
 
http://cvs.php.net/viewvc.cgi/php-src/ext/tokenizer/tests/002.phpt?r1=1.7r2=1.8diff_format=u
Index: php-src/ext/tokenizer/tests/002.phpt
diff -u php-src/ext/tokenizer/tests/002.phpt:1.7 
php-src/ext/tokenizer/tests/002.phpt:1.8
--- php-src/ext/tokenizer/tests/002.phpt:1.7Tue Jun 20 18:14:12 2006
+++ php-src/ext/tokenizer/tests/002.phptSun Apr  8 00:17:40 2007
@@ -22,765 +22,959 @@
 --EXPECT--
 array(49) {
   [0]=
-  array(2) {
+  array(3) {
 [0]=
 int(370)
 [1]=
 string(2) ?
+[2]=
+int(1)
   }
   [1]=
-  array(2) {
+  array(3) {
 [0]=
 int(373)
 [1]=
 string(1)  
+[2]=
+int(1)
   }
   [2]=
-  array(2) {
+  array(3) {
 [0]=
 int(318)
 [1]=
 string(4) echo
+[2]=
+int(1)
   }
   [3]=
-  array(2) {
+  array(3) {
 [0]=
 int(373)
 [1]=
 string(1)  
+[2]=
+int(1)
   }
   [4]=
-  array(2) {
+  array(3) {
 [0]=
 int(307)
 [1]=
 string(1) 1
+[2]=
+int(1)
   }
   [5]=
   string(1) ;
   [6]=
-  array(2) {
+  array(3) {
 [0]=
 int(373)
 [1]=
 string(1)  
+[2]=
+int(1)
   }
   [7]=
-  array(2) {
+  array(3) {
 [0]=
 int(303)
 [1]=
 string(2) if
+[2]=
+int(1)
   }
   [8]=
-  array(2) {
+  array(3) {
 [0]=
 int(373)
 [1]=
 string(1)  
+[2]=
+int(1)
   }
   [9]=
   string(1) (
   [10]=
-  array(2) {
+  array(3) {
 [0]=
 int(352)
 [1]=
 string(5) isset
+[2]=
+int(1)
   }
   [11]=
   string(1) (
   [12]=
-  array(2) {
+  array(3) {
 [0]=
 int(311)
 [1]=
 string(2) $a
+[2]=
+int(1)
   }
   [13]=
   string(1) )
   [14]=
   string(1) )
   [15]=
-  array(2) {
+  array(3) {
 [0]=
 int(373)
 [1]=
 string(1)  
+[2]=
+int(1)
   }
   [16]=
-  array(2) {
+  array(3) {
 [0]=
 int(266)
 [1]=
 string(5) print
+[2]=
+int(1)
   }
   [17]=
-  array(2) {
+  array(3) {
 [0]=
 int(373)
 [1]=
 string(1)  
+[2]=
+int(1)
   }
   [18]=
-  array(2) {
+  array(3) {
 [0]=
 int(311)
 [1]=
 string(2) $a
+[2]=
+int(1)
   }
   [19]=
   string(1) +
   [20]=
-  array(2) {
+  array(3) {
 [0]=
 int(307)
 [1]=
 string(1) 1
+[2]=
+int(1)
   }
   [21]=
   string(1) ;
   [22]=
-  array(2) {
+  array(3) {
 [0]=
 int(373)
 [1]=
 string(1)  
+[2]=
+int(1)
   }
   [23]=
-  array(2) {
+  array(3) {
 [0]=
 int(311)
 [1]=
 string(2) $a
+[2]=
+int(1)
   }
   [24]=
-  array(2) {
+  array(3) {
 [0]=
 int(299)
 [1]=
 string(2) ++
+[2]=
+int(1)
   }
   [25]=
   string(1) ;
   [26]=
-  array(2) {
+  array(3) {
 [0]=
 int(373)
 [1]=
 string(1)  
+[2]=
+int(1)
   }
   [27]=
-  array(2) {
+  array(3) {
 [0]=
 int(311)
 [1]=
 string(2) $a
+[2]=
+int(1)
   }
   [28]=
-  array(2) {
+  array(3) {
 [0]=
 int(298)
 [1]=
 string(2) --
+[2]=
+int(1)
   }
   [29]=
   string(1) ;
   [30]=
-  array(2) {
+  array(3) {
 [0]=
 int(373)
 [1]=
 string(1)  
+[2]=
+int(1)
   }
   [31]=
-  array(2) {
+  array(3) {
 [0]=
 int(311)
 [1]=
 string(2) $a
+[2]=
+int(1)
   }
   [32]=
-  array(2) 

[PHP-CVS] cvs: php-src /ext/reflection/tests bug41061.phpt

2007-04-12 Thread Johannes Schl
johannesThu Apr 12 18:31:57 2007 UTC

  Added files: 
/php-src/ext/reflection/tests   bug41061.phpt 
  Log:
  - Add test
  

http://cvs.php.net/viewvc.cgi/php-src/ext/reflection/tests/bug41061.phpt?view=markuprev=1.1
Index: php-src/ext/reflection/tests/bug41061.phpt
+++ php-src/ext/reflection/tests/bug41061.phpt
--TEST--
Reflection Bug #41061 (visibility error in ReflectionFunction::export())
--SKIPIF--
?php extension_loaded('reflection') or die('skip'); ?
--FILE--
?php

function foo() {
}
 
class bar {
private function foo() {
}
}

Reflection::export(new ReflectionFunction('foo'));
Reflection::export(new ReflectionMethod('bar', 'foo'));
?
===DONE===
?php exit(0); ?
--EXPECTF--
Function [ user function foo ] {
  @@ %sbug41061.php 3 - 4
}

Method [ user private method foo ] {
  @@ %sbug41061.php 7 - 8
}

===DONE===

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



[PHP-CVS] cvs: php-src(PHP_5_2) / NEWS /ext/reflection php_reflection.c /ext/reflection/tests bug41061.phpt

2007-04-12 Thread Johannes Schl
johannesThu Apr 12 18:39:46 2007 UTC

  Added files: (Branch: PHP_5_2)
/php-src/ext/reflection/tests   bug41061.phpt 

  Modified files:  
/php-srcNEWS 
/php-src/ext/reflection php_reflection.c 
  Log:
  - Fix bug #41061 (visibility error in ReflectionFunction::export())
  
  
http://cvs.php.net/viewvc.cgi/php-src/NEWS?r1=1.2027.2.547.2.639r2=1.2027.2.547.2.640diff_format=u
Index: php-src/NEWS
diff -u php-src/NEWS:1.2027.2.547.2.639 php-src/NEWS:1.2027.2.547.2.640
--- php-src/NEWS:1.2027.2.547.2.639 Thu Apr 12 15:28:57 2007
+++ php-src/NEWSThu Apr 12 18:39:45 2007
@@ -2,6 +2,8 @@
 |||
 ?? Apr 2007, PHP 5.2.2RC2
 - Fixed bug #41063 (chdir doesn't like root paths). (Dmitry)
+- Fixed bug #41061 (visibility error in ReflectionFunction::export()).
+  (Johannes)
 - Fixed bug #40861 (strtotime() doesn't handle double negative relative time
   units correctly). (Derick)
 
http://cvs.php.net/viewvc.cgi/php-src/ext/reflection/php_reflection.c?r1=1.164.2.33.2.36r2=1.164.2.33.2.37diff_format=u
Index: php-src/ext/reflection/php_reflection.c
diff -u php-src/ext/reflection/php_reflection.c:1.164.2.33.2.36 
php-src/ext/reflection/php_reflection.c:1.164.2.33.2.37
--- php-src/ext/reflection/php_reflection.c:1.164.2.33.2.36 Sat Mar 17 
23:00:49 2007
+++ php-src/ext/reflection/php_reflection.c Thu Apr 12 18:39:46 2007
@@ -20,7 +20,7 @@
+--+
 */
 
-/* $Id: php_reflection.c,v 1.164.2.33.2.36 2007/03/17 23:00:49 tony2001 Exp $ 
*/
+/* $Id: php_reflection.c,v 1.164.2.33.2.37 2007/04/12 18:39:46 johannes Exp $ 
*/
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -747,23 +747,27 @@
string_printf(str, static );
}
 
-   /* These are mutually exclusive */
-   switch (fptr-common.fn_flags  ZEND_ACC_PPP_MASK) {
-   case ZEND_ACC_PUBLIC:
-   string_printf(str, public );
-   break;
-   case ZEND_ACC_PRIVATE:
-   string_printf(str, private );
-   break;
-   case ZEND_ACC_PROTECTED:
-   string_printf(str, protected );
-   break;
-   default:
-   string_printf(str, visibility error );
-   break;
+   if (fptr-common.scope) {
+   /* These are mutually exclusive */
+   switch (fptr-common.fn_flags  ZEND_ACC_PPP_MASK) {
+   case ZEND_ACC_PUBLIC:
+   string_printf(str, public );
+   break;
+   case ZEND_ACC_PRIVATE:
+   string_printf(str, private );
+   break;
+   case ZEND_ACC_PROTECTED:
+   string_printf(str, protected );
+   break;
+   default:
+   string_printf(str, visibility error );
+   break;
+   }
+   string_printf(str, method );
+   } else {
+   string_printf(str, function );
}
 
-   string_printf(str, fptr-common.scope ? method  : function );
if (fptr-op_array.return_reference) {
string_printf(str, );
}
@@ -4889,7 +4893,7 @@
php_info_print_table_start();
php_info_print_table_header(2, Reflection, enabled);
 
-   php_info_print_table_row(2, Version, $Id: php_reflection.c,v 
1.164.2.33.2.36 2007/03/17 23:00:49 tony2001 Exp $);
+   php_info_print_table_row(2, Version, $Id: php_reflection.c,v 
1.164.2.33.2.37 2007/04/12 18:39:46 johannes Exp $);
 
php_info_print_table_end();
 } /* }}} */

http://cvs.php.net/viewvc.cgi/php-src/ext/reflection/tests/bug41061.phpt?view=markuprev=1.1
Index: php-src/ext/reflection/tests/bug41061.phpt
+++ php-src/ext/reflection/tests/bug41061.phpt
--TEST--
Reflection Bug #41061 (visibility error in ReflectionFunction::export())
--SKIPIF--
?php extension_loaded('reflection') or die('skip'); ?
--FILE--
?php

function foo() {
}
 
class bar {
private function foo() {
}
}

Reflection::export(new ReflectionFunction('foo'));
Reflection::export(new ReflectionMethod('bar', 'foo'));
?
===DONE===
?php exit(0); ?
--EXPECTF--
Function [ user function foo ] {
  @@ %sbug41061.php 3 - 4
}

Method [ user private method foo ] {
  @@ %sbug41061.php 7 - 8
}

===DONE===

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



[PHP-CVS] cvs: php-src /sapi/cli php.1.in

2007-04-23 Thread Johannes Schl
johannesMon Apr 23 20:53:55 2007 UTC

  Modified files:  
/php-src/sapi/cli   php.1.in 
  Log:
  - Add my name (sync to CREDITS file)
  
http://cvs.php.net/viewvc.cgi/php-src/sapi/cli/php.1.in?r1=1.19r2=1.20diff_format=u
Index: php-src/sapi/cli/php.1.in
diff -u php-src/sapi/cli/php.1.in:1.19 php-src/sapi/cli/php.1.in:1.20
--- php-src/sapi/cli/php.1.in:1.19  Mon Apr 23 20:47:58 2007
+++ php-src/sapi/cli/php.1.in   Mon Apr 23 20:53:55 2007
@@ -390,7 +390,7 @@
 .SH AUTHORS
 The PHP Group: Thies C. Arntzen, Stig Bakken, Andi Gutmans, Rasmus Lerdorf, 
Sam Ruby, Sascha Schumann, Zeev Suraski, Jim Winstead, Andrei Zmievski.
 .P
-Additional work for the CLI sapi was done by Edin Kadribasic and Marcus 
Boerger.
+Additional work for the CLI sapi was done by Edin Kadribasic, Marcus Boerger 
and Johannes Schlueter.
 .P
 A List of active developers can be found here:
 .PD 0

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



[PHP-CVS] cvs: php-src(PHP_5_2) /sapi/cli php.1.in

2007-04-23 Thread Johannes Schl
johannesMon Apr 23 20:54:22 2007 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/sapi/cli   php.1.in 
  Log:
  - MFH: Add my name (sync to CREDITS file)
  
http://cvs.php.net/viewvc.cgi/php-src/sapi/cli/php.1.in?r1=1.12.2.3.2.2r2=1.12.2.3.2.3diff_format=u
Index: php-src/sapi/cli/php.1.in
diff -u php-src/sapi/cli/php.1.in:1.12.2.3.2.2 
php-src/sapi/cli/php.1.in:1.12.2.3.2.3
--- php-src/sapi/cli/php.1.in:1.12.2.3.2.2  Thu Feb  8 16:55:34 2007
+++ php-src/sapi/cli/php.1.in   Mon Apr 23 20:54:22 2007
@@ -387,7 +387,7 @@
 .SH AUTHORS
 The PHP Group: Thies C. Arntzen, Stig Bakken, Andi Gutmans, Rasmus Lerdorf, 
Sam Ruby, Sascha Schumann, Zeev Suraski, Jim Winstead, Andrei Zmievski.
 .P
-Additional work for the CLI sapi was done by Edin Kadribasic and Marcus 
Boerger.
+Additional work for the CLI sapi was done by Edin Kadribasic, Marcus Boerger 
and Johannes Schlueter.
 .P
 A List of active developers can be found here:
 .PD 0

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



[PHP-CVS] cvs: php-src / run-tests.php

2007-04-23 Thread Johannes Schl
johannesMon Apr 23 20:55:56 2007 UTC

  Modified files:  
/php-srcrun-tests.php 
  Log:
  - Keep unicode.semantcis for SKIPIF
  
http://cvs.php.net/viewvc.cgi/php-src/run-tests.php?r1=1.319r2=1.320diff_format=u
Index: php-src/run-tests.php
diff -u php-src/run-tests.php:1.319 php-src/run-tests.php:1.320
--- php-src/run-tests.php:1.319 Mon Apr 23 11:19:05 2007
+++ php-src/run-tests.php   Mon Apr 23 20:55:56 2007
@@ -23,7 +23,7 @@
+--+
  */
 
-/* $Id: run-tests.php,v 1.319 2007/04/23 11:19:05 tony2001 Exp $ */
+/* $Id: run-tests.php,v 1.320 2007/04/23 20:55:56 johannes Exp $ */
 
 /* Sanity check to ensure that pcre extension needed by this script is 
available.
  * In the event it is not, print a nice error message indicating that this 
script will
@@ -405,7 +405,7 @@
$html_output = is_resource($html_file);
break;
case '--version':
-   echo '$Revision: 1.319 $'.\n;
+   echo '$Revision: 1.320 $'.\n;
exit(1);
default:
echo Illegal switch specified!\n;
@@ -1212,6 +1212,9 @@
save_text($test_skipif, $section_text['SKIPIF'], 
$temp_skipif);
$extra = substr(PHP_OS, 0, 3) !== WIN ?
unset REQUEST_METHOD; unset QUERY_STRING; 
unset PATH_TRANSLATED; unset SCRIPT_FILENAME; unset REQUEST_METHOD;: ;
+
+   $ini_settings .=  -dunicode.semantics= . 
(int)$unicode_test;
+
$output = system_with_timeout($extra $php -q 
$ini_settings $test_skipif, $env);
if (!$cfg['keep']['skip']) {
@unlink($test_skipif);

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



[PHP-CVS] cvs: php-src /tests/classes bug26737.phpt

2007-04-26 Thread Johannes Schl
johannesThu Apr 26 07:19:29 2007 UTC

  Modified files:  
/php-src/tests/classes  bug26737.phpt 
  Log:
  - Fix test
  
http://cvs.php.net/viewvc.cgi/php-src/tests/classes/bug26737.phpt?r1=1.6r2=1.7diff_format=u
Index: php-src/tests/classes/bug26737.phpt
diff -u php-src/tests/classes/bug26737.phpt:1.6 
php-src/tests/classes/bug26737.phpt:1.7
--- php-src/tests/classes/bug26737.phpt:1.6 Mon Feb 19 20:02:08 2007
+++ php-src/tests/classes/bug26737.phpt Thu Apr 26 07:19:29 2007
@@ -18,7 +18,7 @@
 var_dump(str_replace(\0, '\0', $data));
 ?
 --EXPECTF--
-Notice: serialize(): no_such returned as member variable from __sleep() but 
does not exist in /local/dev/php/head/tests/classes/bug26737.php on line 14
+Notice: serialize(): no_such returned as member variable from __sleep() but 
does not exist in %s on line %d
 string(130) 
O:3:foo:4:{S:12:\0foo\0private;S:7:private;S:12:\0*\0protected;S:9:protected;S:6:public;S:6:public;S:7:no_such;N;}
 --UEXPECTF--
 Notice: serialize(): no_such returned as member variable from __sleep() but 
does not exist in %s on line %d

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



[PHP-CVS] cvs: php-src /ext/spl/tests spl_007.phpt

2007-04-30 Thread Johannes Schl
johannesMon Apr 30 19:52:04 2007 UTC

  Added files: 
/php-src/ext/spl/tests  spl_007.phpt 
  Log:
  - Add new test
  

http://cvs.php.net/viewvc.cgi/php-src/ext/spl/tests/spl_007.phpt?view=markuprev=1.1
Index: php-src/ext/spl/tests/spl_007.phpt
+++ php-src/ext/spl/tests/spl_007.phpt
--TEST--
SPL: iterator_apply() with callback using __call()
--SKIPIF--
?php if (!extension_loaded(spl)) print skip; ?
--FILE--
?php

class Foo {
public function __call($name, $params) {
echo Called $name.\n;
return true;
}
}

$it = new ArrayIterator(array(1, 2, 3));

iterator_apply($it, array(new Foo, foobar));

?
===DONE===
?php exit(0); ?
--EXPECT--
Called foobar.
Called foobar.
Called foobar.
===DONE===

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



[PHP-CVS] cvs: php-src(PHP_5_2) / NEWS

2007-04-30 Thread Johannes Schl
johannesMon Apr 30 20:01:17 2007 UTC

  Modified files:  (Branch: PHP_5_2)
/php-srcNEWS 
  Log:
  BFN
  
http://cvs.php.net/viewvc.cgi/php-src/NEWS?r1=1.2027.2.547.2.667r2=1.2027.2.547.2.668diff_format=u
Index: php-src/NEWS
diff -u php-src/NEWS:1.2027.2.547.2.667 php-src/NEWS:1.2027.2.547.2.668
--- php-src/NEWS:1.2027.2.547.2.667 Sun Apr 29 14:47:33 2007
+++ php-src/NEWSMon Apr 30 20:01:16 2007
@@ -1,6 +1,7 @@
 PHPNEWS
 |||
 ?? Apr 2007, PHP 5.2.3RC3
+- Fixed iterator_apply() with a callback using __call(). (Johannes)
 - Fixed bug #41215 (setAttribute return code reversed). (Ilia)
 
 26 Apr 2007, PHP 5.2.2RC2

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



[PHP-CVS] cvs: php-src /ext/dom/tests dom_xinclude.phpt

2007-05-01 Thread Johannes Schl
johannesTue May  1 08:35:57 2007 UTC

  Modified files:  
/php-src/ext/dom/tests  dom_xinclude.phpt 
  Log:
  - Fix test
  
http://cvs.php.net/viewvc.cgi/php-src/ext/dom/tests/dom_xinclude.phpt?r1=1.5r2=1.6diff_format=u
Index: php-src/ext/dom/tests/dom_xinclude.phpt
diff -u php-src/ext/dom/tests/dom_xinclude.phpt:1.5 
php-src/ext/dom/tests/dom_xinclude.phpt:1.6
--- php-src/ext/dom/tests/dom_xinclude.phpt:1.5 Thu Oct 20 19:22:54 2005
+++ php-src/ext/dom/tests/dom_xinclude.phpt Tue May  1 08:35:57 2007
@@ -12,7 +12,7 @@
 $data = file_get_contents(dirname(__FILE__)./xinclude.xml);
 $data = 
str_replace('compress.zlib://ext/dom/tests/','compress.zlib://'.dirname(__FILE__).'/',
 $data);
 
-$dom-loadXML($data);
+$dom-loadXML((binary)$data);
 
 $dom-xinclude();
 print $dom-saveXML().\n;

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



[PHP-CVS] cvs: php-src /sapi/cli php_cli.c

2007-05-06 Thread Johannes Schl
johannesSun May  6 12:57:28 2007 UTC

  Modified files:  
/php-src/sapi/cli   php_cli.c 
  Log:
  - Fix build without reflection
  # reflection_what is used fby --ri, too
  
  
http://cvs.php.net/viewvc.cgi/php-src/sapi/cli/php_cli.c?r1=1.178r2=1.179diff_format=u
Index: php-src/sapi/cli/php_cli.c
diff -u php-src/sapi/cli/php_cli.c:1.178 php-src/sapi/cli/php_cli.c:1.179
--- php-src/sapi/cli/php_cli.c:1.178Sat May  5 12:46:30 2007
+++ php-src/sapi/cli/php_cli.c  Sun May  6 12:57:27 2007
@@ -20,7 +20,7 @@
+--+
 */
 
-/* $Id: php_cli.c,v 1.178 2007/05/05 12:46:30 helly Exp $ */
+/* $Id: php_cli.c,v 1.179 2007/05/06 12:57:27 johannes Exp $ */
 
 #include php.h
 #include php_globals.h
@@ -595,9 +595,7 @@
zend_file_handle file_handle;
 /* temporary locals */
enum behavior_mode behavior = PHP_MODE_STANDARD;
-#ifdef HAVE_REFLECTION
char *reflection_what = NULL;
-#endif
int orig_optind=php_optind;
char *orig_optarg=php_optarg;
char *arg_free=NULL, **arg_excp=arg_free;

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



[PHP-CVS] cvs: php-src(PHP_5_2) /sapi/cli php_cli.c

2007-05-06 Thread Johannes Schl
johannesSun May  6 12:57:50 2007 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/sapi/cli   php_cli.c 
  Log:
  - MFH: Fix build without reflection
  
http://cvs.php.net/viewvc.cgi/php-src/sapi/cli/php_cli.c?r1=1.129.2.13.2.19r2=1.129.2.13.2.20diff_format=u
Index: php-src/sapi/cli/php_cli.c
diff -u php-src/sapi/cli/php_cli.c:1.129.2.13.2.19 
php-src/sapi/cli/php_cli.c:1.129.2.13.2.20
--- php-src/sapi/cli/php_cli.c:1.129.2.13.2.19  Sat May  5 16:21:07 2007
+++ php-src/sapi/cli/php_cli.c  Sun May  6 12:57:50 2007
@@ -20,7 +20,7 @@
+--+
 */
 
-/* $Id: php_cli.c,v 1.129.2.13.2.19 2007/05/05 16:21:07 helly Exp $ */
+/* $Id: php_cli.c,v 1.129.2.13.2.20 2007/05/06 12:57:50 johannes Exp $ */
 
 #include php.h
 #include php_globals.h
@@ -580,9 +580,7 @@
zend_file_handle file_handle;
 /* temporary locals */
int behavior=PHP_MODE_STANDARD;
-#ifdef HAVE_REFLECTION
char *reflection_what = NULL;
-#endif
int orig_optind=php_optind;
char *orig_optarg=php_optarg;
char *arg_free=NULL, **arg_excp=arg_free;

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



[PHP-CVS] cvs: php-src / README.UPDATING_TO_PHP6

2007-05-18 Thread Johannes Schl
johannesFri May 18 12:38:07 2007 UTC

  Modified files:  
/php-srcREADME.UPDATING_TO_PHP6 
  Log:
  - Use the right variable name
  
http://cvs.php.net/viewvc.cgi/php-src/README.UPDATING_TO_PHP6?r1=1.4r2=1.5diff_format=u
Index: php-src/README.UPDATING_TO_PHP6
diff -u php-src/README.UPDATING_TO_PHP6:1.4 php-src/README.UPDATING_TO_PHP6:1.5
--- php-src/README.UPDATING_TO_PHP6:1.4 Thu Mar 30 14:08:38 2006
+++ php-src/README.UPDATING_TO_PHP6 Fri May 18 12:38:07 2007
@@ -128,7 +128,7 @@
$HTTP_COOKIE_VARS = $_COOKIE;
$HTTP_SERVER_VARS = $_SERVER;
$HTTP_ENV_VARS = $_ENV;
-   $HTTP_FILES_VARS = $_FILES;
+   $HTTP_POST_FILES = $_FILES;
 }
 ?
 

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



[PHP-CVS] cvs: php-src /ext/simplexml/tests bug37565.phpt

2007-06-12 Thread Johannes Schl
johannesTue Jun 12 17:23:57 2007 UTC

  Modified files:  
/php-src/ext/simplexml/testsbug37565.phpt 
  Log:
  - Fix test
  
http://cvs.php.net/viewvc.cgi/php-src/ext/simplexml/tests/bug37565.phpt?r1=1.5r2=1.6diff_format=u
Index: php-src/ext/simplexml/tests/bug37565.phpt
diff -u php-src/ext/simplexml/tests/bug37565.phpt:1.5 
php-src/ext/simplexml/tests/bug37565.phpt:1.6
--- php-src/ext/simplexml/tests/bug37565.phpt:1.5   Mon May  7 17:23:04 2007
+++ php-src/ext/simplexml/tests/bug37565.phpt   Tue Jun 12 17:23:57 2007
@@ -1,7 +1,7 @@
 --TEST--
 Bug #37565 (Using reflection::export with simplexml causing a crash)
 --SKIPIF--
-?php if (!extension_loaded(simplexml)) print skip; ?
+?php if (!extension_loaded(simplexml) || !extension_loaded('reflection')) 
print skip; ?
 --FILE--
 ?php
 function my_error_handler($errno, $errstr, $errfile, $errline) {

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



[PHP-CVS] cvs: php-src(PHP_5_2) /ext/simplexml/tests bug37565.phpt

2007-06-12 Thread Johannes Schl
johannesTue Jun 12 17:24:38 2007 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/ext/simplexml/testsbug37565.phpt 
  Log:
  - MFH: Fix test
  
http://cvs.php.net/viewvc.cgi/php-src/ext/simplexml/tests/bug37565.phpt?r1=1.1.2.5r2=1.1.2.6diff_format=u
Index: php-src/ext/simplexml/tests/bug37565.phpt
diff -u php-src/ext/simplexml/tests/bug37565.phpt:1.1.2.5 
php-src/ext/simplexml/tests/bug37565.phpt:1.1.2.6
--- php-src/ext/simplexml/tests/bug37565.phpt:1.1.2.5   Mon May  7 18:03:00 2007
+++ php-src/ext/simplexml/tests/bug37565.phpt   Tue Jun 12 17:24:38 2007
@@ -1,7 +1,7 @@
 --TEST--
 Bug #37565 (Using reflection::export with simplexml causing a crash)
 --SKIPIF--
-?php if (!extension_loaded(simplexml)) print skip; ?
+?php if (!extension_loaded(simplexml) || !extension_loaded('reflection')) 
print skip; ?
 --FILE--
 ?php
 

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



[PHP-CVS] cvs: php-src(PHP_5_2) / NEWS /ext/reflection php_reflection.c /ext/reflection/tests 026.phpt

2007-07-24 Thread Johannes Schl�ter
johannesTue Jul 24 23:15:59 2007 UTC

  Added files: (Branch: PHP_5_2)
/php-src/ext/reflection/tests   026.phpt 

  Modified files:  
/php-srcNEWS 
/php-src/ext/reflection php_reflection.c 
  Log:
  - New ReflectionExtension::info() function to print the phpinfo() block
for an extension. [DOC]
  
  
http://cvs.php.net/viewvc.cgi/php-src/NEWS?r1=1.2027.2.547.2.857r2=1.2027.2.547.2.858diff_format=u
Index: php-src/NEWS
diff -u php-src/NEWS:1.2027.2.547.2.857 php-src/NEWS:1.2027.2.547.2.858
--- php-src/NEWS:1.2027.2.547.2.857 Tue Jul 24 22:57:13 2007
+++ php-src/NEWSTue Jul 24 23:15:58 2007
@@ -35,6 +35,8 @@
   (Andrey A. Belashkov, Tony)
 - Added missing MSG_EOR and MSG_EOF constants to sockets extension. (Jani)
 - Added PCRE_VERSION constant. (Tony)
+- Added ReflectionExtension::info() function to print the phpinfo() block for
+  an extension. (Johannes)
 
 - Implemented FR #41884 (ReflectionClass::getDefaultProperties() does not 
handle 
   static attributes). (Tony)
http://cvs.php.net/viewvc.cgi/php-src/ext/reflection/php_reflection.c?r1=1.164.2.33.2.42r2=1.164.2.33.2.43diff_format=u
Index: php-src/ext/reflection/php_reflection.c
diff -u php-src/ext/reflection/php_reflection.c:1.164.2.33.2.42 
php-src/ext/reflection/php_reflection.c:1.164.2.33.2.43
--- php-src/ext/reflection/php_reflection.c:1.164.2.33.2.42 Mon Jul 23 
01:13:43 2007
+++ php-src/ext/reflection/php_reflection.c Tue Jul 24 23:15:58 2007
@@ -20,7 +20,7 @@
+--+
 */
 
-/* $Id: php_reflection.c,v 1.164.2.33.2.42 2007/07/23 01:13:43 bjori Exp $ */
+/* $Id: php_reflection.c,v 1.164.2.33.2.43 2007/07/24 23:15:58 johannes Exp $ 
*/
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -4394,6 +4394,20 @@
 }
 /* }}} */
 
+/* {{{ proto public void ReflectionExtension::info() U
+   Prints phpinfo block for the extension */
+ZEND_METHOD(reflection_extension, info)
+{
+   reflection_object *intern;
+   zend_module_entry *module;
+
+   METHOD_NOTSTATIC_NUMPARAMS(reflection_extension_ptr, 0);
+   GET_REFLECTION_OBJECT_PTR(module);
+
+   php_info_print_module(module TSRMLS_CC);
+}
+/* }}} */
+
 /* {{{ method tables */
 static zend_function_entry reflection_exception_functions[] = {
{NULL, NULL, NULL}
@@ -4770,6 +4784,7 @@
ZEND_ME(reflection_extension, getClasses, NULL, 0)
ZEND_ME(reflection_extension, getClassNames, NULL, 0)
ZEND_ME(reflection_extension, getDependencies, NULL, 0)
+   ZEND_ME(reflection_extension, info, NULL, 0)
{NULL, NULL, NULL}
 };
 /* }}} */
@@ -4888,7 +4903,7 @@
php_info_print_table_start();
php_info_print_table_header(2, Reflection, enabled);
 
-   php_info_print_table_row(2, Version, $Id: php_reflection.c,v 
1.164.2.33.2.42 2007/07/23 01:13:43 bjori Exp $);
+   php_info_print_table_row(2, Version, $Id: php_reflection.c,v 
1.164.2.33.2.43 2007/07/24 23:15:58 johannes Exp $);
 
php_info_print_table_end();
 } /* }}} */

http://cvs.php.net/viewvc.cgi/php-src/ext/reflection/tests/026.phpt?view=markuprev=1.1
Index: php-src/ext/reflection/tests/026.phpt
+++ php-src/ext/reflection/tests/026.phpt

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



[PHP-CVS] cvs: php-src /ext/reflection php_reflection.c /ext/reflection/tests 026.phpt

2007-07-24 Thread Johannes Schl�ter
johannesTue Jul 24 23:16:47 2007 UTC

  Modified files:  
/php-src/ext/reflection php_reflection.c 
/php-src/ext/reflection/tests   026.phpt 
  Log:
  - MFB: New ReflectionExtension::info() function to print the phpinfo() block
for an extension.
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/reflection/php_reflection.c?r1=1.279r2=1.280diff_format=u
Index: php-src/ext/reflection/php_reflection.c
diff -u php-src/ext/reflection/php_reflection.c:1.279 
php-src/ext/reflection/php_reflection.c:1.280
--- php-src/ext/reflection/php_reflection.c:1.279   Mon Jul 23 01:21:04 2007
+++ php-src/ext/reflection/php_reflection.c Tue Jul 24 23:16:47 2007
@@ -20,7 +20,7 @@
+--+
 */
 
-/* $Id: php_reflection.c,v 1.279 2007/07/23 01:21:04 bjori Exp $ */
+/* $Id: php_reflection.c,v 1.280 2007/07/24 23:16:47 johannes Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -4512,6 +4512,20 @@
 }
 /* }}} */
 
+/* {{{ proto public void ReflectionExtension::info() U
+   Prints phpinfo block for the extension */
+ZEND_METHOD(reflection_extension, info)
+{
+   reflection_object *intern;
+   zend_module_entry *module;
+
+   METHOD_NOTSTATIC_NUMPARAMS(reflection_extension_ptr, 0);
+   GET_REFLECTION_OBJECT_PTR(module);
+
+   php_info_print_module(module TSRMLS_CC);
+}
+/* }}} */
+
 /* {{{ method tables */
 static zend_function_entry reflection_exception_functions[] = {
{NULL, NULL, NULL}
@@ -4889,6 +4903,7 @@
ZEND_ME(reflection_extension, getClasses, NULL, 0)
ZEND_ME(reflection_extension, getClassNames, NULL, 0)
ZEND_ME(reflection_extension, getDependencies, NULL, 0)
+   ZEND_ME(reflection_extension, info, NULL, 0)
{NULL, NULL, NULL}
 };
 /* }}} */
@@ -5007,7 +5022,7 @@
php_info_print_table_start();
php_info_print_table_header(2, Reflection, enabled);
 
-   php_info_print_table_row(2, Version, $Id: php_reflection.c,v 1.279 
2007/07/23 01:21:04 bjori Exp $);
+   php_info_print_table_row(2, Version, $Id: php_reflection.c,v 1.280 
2007/07/24 23:16:47 johannes Exp $);
 
php_info_print_table_end();
 } /* }}} */
http://cvs.php.net/viewvc.cgi/php-src/ext/reflection/tests/026.phpt?r1=1.1r2=1.2diff_format=u
Index: php-src/ext/reflection/tests/026.phpt
diff -u /dev/null php-src/ext/reflection/tests/026.phpt:1.2
--- /dev/null   Tue Jul 24 23:16:47 2007
+++ php-src/ext/reflection/tests/026.phpt   Tue Jul 24 23:16:47 2007
@@ -0,0 +1,36 @@
+--TEST--
+reflectionExtension::info()
+--SKIPIF--
+?php extension_loaded('reflection') or die('skip'); ?
+--FILE--
+?php
+$r = new ReflectionExtension(reflection);
+$r-info();
+
+date_default_timezone_set('Europe/Berlin');
+$r = new ReflectionExtension(date);
+$r-info();
+
+echo \nDone!\n;
+
+--EXPECTF--
+Reflection
+
+Reflection = enabled
+Version = %s
+
+date
+
+date/time support = enabled
+Olson Timezone Database Version = %s
+Timezone Database = %s
+Default timezone = %s
+
+Directive = %s = %s
+date.timezone = %s = %s
+date.default_latitude = %s = %s
+date.default_longitude = %s = %s
+date.sunset_zenith = %s = %s
+date.sunrise_zenith = %s = %s
+
+Done!

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



[PHP-CVS] cvs: php-src /ext/tokenizer CREDITS config.m4 php_tokenizer.h tokenizer.c tokenizer_data.c tokenizer_data_gen.sh

2007-07-31 Thread Johannes Schl�ter
johannesTue Jul 31 23:23:37 2007 UTC

  Added files: 
/php-src/ext/tokenizer  tokenizer_data.c tokenizer_data_gen.sh 

  Modified files:  
/php-src/ext/tokenizer  CREDITS config.m4 php_tokenizer.h 
tokenizer.c 
  Log:
  - Use a script to generate tokenizer data from zend_language_parser.h
  
  http://cvs.php.net/viewvc.cgi/php-src/ext/tokenizer/CREDITS?r1=1.2r2=1.3diff_format=u
Index: php-src/ext/tokenizer/CREDITS
diff -u php-src/ext/tokenizer/CREDITS:1.2 php-src/ext/tokenizer/CREDITS:1.3
--- php-src/ext/tokenizer/CREDITS:1.2   Sat Mar  2 13:44:06 2002
+++ php-src/ext/tokenizer/CREDITS   Tue Jul 31 23:23:37 2007
@@ -1,2 +1,2 @@
 tokenizer
-Andrei Zmievski
+Andrei Zmievski, Johannes Schlueter
http://cvs.php.net/viewvc.cgi/php-src/ext/tokenizer/config.m4?r1=1.5r2=1.6diff_format=u
Index: php-src/ext/tokenizer/config.m4
diff -u php-src/ext/tokenizer/config.m4:1.5 php-src/ext/tokenizer/config.m4:1.6
--- php-src/ext/tokenizer/config.m4:1.5 Tue Apr 16 05:37:51 2002
+++ php-src/ext/tokenizer/config.m4 Tue Jul 31 23:23:37 2007
@@ -1,4 +1,4 @@
-dnl $Id: config.m4,v 1.5 2002/04/16 05:37:51 ssb Exp $
+dnl $Id: config.m4,v 1.6 2007/07/31 23:23:37 johannes Exp $
 dnl config.m4 for extension tokenizer
 
 dnl Otherwise use enable:
@@ -7,6 +7,6 @@
 [  --disable-tokenizer Disable tokenizer support], yes)
 
 if test $PHP_TOKENIZER != no; then
-  PHP_NEW_EXTENSION(tokenizer, tokenizer.c, $ext_shared)
+  PHP_NEW_EXTENSION(tokenizer, tokenizer.c tokenizer_data.c, $ext_shared)
   PHP_ADD_MAKEFILE_FRAGMENT
 fi
http://cvs.php.net/viewvc.cgi/php-src/ext/tokenizer/php_tokenizer.h?r1=1.13r2=1.14diff_format=u
Index: php-src/ext/tokenizer/php_tokenizer.h
diff -u php-src/ext/tokenizer/php_tokenizer.h:1.13 
php-src/ext/tokenizer/php_tokenizer.h:1.14
--- php-src/ext/tokenizer/php_tokenizer.h:1.13  Mon May 28 12:18:26 2007
+++ php-src/ext/tokenizer/php_tokenizer.h   Tue Jul 31 23:23:37 2007
@@ -16,7 +16,7 @@
+--+
  */
 
-/* $Id: php_tokenizer.h,v 1.13 2007/05/28 12:18:26 bjori Exp $ */
+/* $Id: php_tokenizer.h,v 1.14 2007/07/31 23:23:37 johannes Exp $ */
 
 #ifndef PHP_TOKENIZER_H
 #define PHP_TOKENIZER_H
@@ -34,6 +34,10 @@
 #include TSRM.h
 #endif
 
+void tokenizer_register_constants(INIT_FUNC_ARGS);
+char *get_token_type_name(int token_type);
+
+
 PHP_MINIT_FUNCTION(tokenizer);
 PHP_MINFO_FUNCTION(tokenizer);
 
http://cvs.php.net/viewvc.cgi/php-src/ext/tokenizer/tokenizer.c?r1=1.42r2=1.43diff_format=u
Index: php-src/ext/tokenizer/tokenizer.c
diff -u php-src/ext/tokenizer/tokenizer.c:1.42 
php-src/ext/tokenizer/tokenizer.c:1.43
--- php-src/ext/tokenizer/tokenizer.c:1.42  Fri May 18 13:12:47 2007
+++ php-src/ext/tokenizer/tokenizer.c   Tue Jul 31 23:23:37 2007
@@ -16,7 +16,7 @@
+--+
 */
 
-/* $Id: tokenizer.c,v 1.42 2007/05/18 13:12:47 dmitry Exp $ */
+/* $Id: tokenizer.c,v 1.43 2007/07/31 23:23:37 johannes Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -132,126 +132,7 @@
  */
 PHP_MINIT_FUNCTION(tokenizer)
 {
-   REGISTER_LONG_CONSTANT(T_INCLUDE, T_INCLUDE, CONST_CS | 
CONST_PERSISTENT);
-   REGISTER_LONG_CONSTANT(T_INCLUDE_ONCE, T_INCLUDE_ONCE, CONST_CS | 
CONST_PERSISTENT);
-   REGISTER_LONG_CONSTANT(T_EVAL, T_EVAL, CONST_CS | CONST_PERSISTENT);
-   REGISTER_LONG_CONSTANT(T_REQUIRE, T_REQUIRE, CONST_CS | 
CONST_PERSISTENT);
-   REGISTER_LONG_CONSTANT(T_REQUIRE_ONCE, T_REQUIRE_ONCE, CONST_CS | 
CONST_PERSISTENT);
-   REGISTER_LONG_CONSTANT(T_LOGICAL_OR, T_LOGICAL_OR, CONST_CS | 
CONST_PERSISTENT);
-   REGISTER_LONG_CONSTANT(T_LOGICAL_XOR, T_LOGICAL_XOR, CONST_CS | 
CONST_PERSISTENT);
-   REGISTER_LONG_CONSTANT(T_LOGICAL_AND, T_LOGICAL_AND, CONST_CS | 
CONST_PERSISTENT);
-   REGISTER_LONG_CONSTANT(T_PRINT, T_PRINT, CONST_CS | CONST_PERSISTENT);
-   REGISTER_LONG_CONSTANT(T_PLUS_EQUAL, T_PLUS_EQUAL, CONST_CS | 
CONST_PERSISTENT);
-   REGISTER_LONG_CONSTANT(T_MINUS_EQUAL, T_MINUS_EQUAL, CONST_CS | 
CONST_PERSISTENT);
-   REGISTER_LONG_CONSTANT(T_MUL_EQUAL, T_MUL_EQUAL, CONST_CS | 
CONST_PERSISTENT);
-   REGISTER_LONG_CONSTANT(T_DIV_EQUAL, T_DIV_EQUAL, CONST_CS | 
CONST_PERSISTENT);
-   REGISTER_LONG_CONSTANT(T_CONCAT_EQUAL, T_CONCAT_EQUAL, CONST_CS | 
CONST_PERSISTENT);
-   REGISTER_LONG_CONSTANT(T_MOD_EQUAL, T_MOD_EQUAL, CONST_CS | 
CONST_PERSISTENT);
-   REGISTER_LONG_CONSTANT(T_AND_EQUAL, T_AND_EQUAL, CONST_CS | 
CONST_PERSISTENT);
-   REGISTER_LONG_CONSTANT(T_OR_EQUAL, T_OR_EQUAL, CONST_CS | 
CONST_PERSISTENT);
-   REGISTER_LONG_CONSTANT(T_XOR_EQUAL, T_XOR_EQUAL, CONST_CS | 
CONST_PERSISTENT);
-   REGISTER_LONG_CONSTANT(T_SL_EQUAL, T_SL_EQUAL, CONST_CS | 
CONST_PERSISTENT);
-   REGISTER_LONG_CONSTANT(T_SR_EQUAL, T_SR_EQUAL, CONST_CS | 
CONST_PERSISTENT);
-   REGISTER_LONG_CONSTANT(T_BOOLEAN_OR, 

  1   2   >