com php-src: final ext/session fixes: ext/session/mod_files .c ext/session/php_session.h ext/session/session.c ext/session/tests/016.phpt
ext/session/tests/sessi on_hash_function_basic.phpt ext/session/tests/session _save_path_variation2.phpt ext/session/tests/sessio
n_serializer_name_basic.phpt

From: Date: Wed, 27 Nov 2013 14:33:40 +0000
Subject: com php-src: final ext/session fixes: ext/session/mod_files .c ext/session/php_session.h ext/session/session.c ext/session/tests/016.phpt
ext/session/tests/sessi on_hash_function_basic.phpt ext/session/tests/session _save_path_variation2.phpt ext/session/tests/sessio
n_serializer_name_basic.phpt
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-74094@lists.php.net to get a copy of this message
Commit: 0fd48b2f4850c0e92f1d23a3d8d332b44d689c90 Author: Anatol Belski <ab@php.net> Wed, 27 Nov 2013 15:33:40 +0100 Parents: bec270ffc877815e9feffd80eecf9f807f6d6c89 Branches: str_size_and_int64 Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=0fd48b2f4850c0e92f1d23a3d8d332b44d689c90 Log: final ext/session fixes Changed paths: M ext/session/mod_files.c M ext/session/php_session.h M ext/session/session.c M ext/session/tests/016.phpt M ext/session/tests/session_hash_function_basic.phpt M ext/session/tests/session_save_path_variation2.phpt M ext/session/tests/session_serializer_name_basic.phpt Diff: diff --git a/ext/session/mod_files.c b/ext/session/mod_files.c index dec0d5d..6451b5d 100644 --- a/ext/session/mod_files.c +++ b/ext/session/mod_files.c @@ -322,7 +322,7 @@ PS_CLOSE_FUNC(files) PS_READ_FUNC(files) { - long n; + php_int_t n; struct stat sbuf; PS_FILES_DATA; @@ -384,7 +384,7 @@ PS_READ_FUNC(files) PS_WRITE_FUNC(files) { - long n; + php_int_t n; PS_FILES_DATA; ps_files_open(data, key TSRMLS_CC); diff --git a/ext/session/php_session.h b/ext/session/php_session.h index f732e27..0c47043 100644 --- a/ext/session/php_session.h +++ b/ext/session/php_session.h @@ -162,11 +162,11 @@ typedef struct _php_ps_globals { zend_bool use_trans_sid; /* contains the INI value of whether to use trans-sid */ zend_bool apply_trans_sid; /* whether or not to enable trans-sid for the current request */ - long hash_func; + php_int_t hash_func; #if defined(HAVE_HASH_EXT) && !defined(COMPILE_DL_HASH) php_hash_ops *hash_ops; #endif - long hash_bits_per_character; + php_int_t hash_bits_per_character; int send_cookie; int define_sid; zend_bool invalid_session_id; /* allows the driver to report about an invalid session id and request id regeneration */ @@ -176,7 +176,7 @@ typedef struct _php_ps_globals { zend_bool rfc1867_cleanup; /* session.upload_progress.cleanup */ smart_str rfc1867_prefix; /* session.upload_progress.prefix */ smart_str rfc1867_name; /* session.upload_progress.name */ - long rfc1867_freq; /* session.upload_progress.freq */ + php_int_t rfc1867_freq; /* session.upload_progress.freq */ double rfc1867_min_freq; /* session.upload_progress.min_freq */ zend_bool use_strict_mode; /* whether or not PHP accepts unknown session ids */ diff --git a/ext/session/session.c b/ext/session/session.c index f2a861f..4b126dd 100644 --- a/ext/session/session.c +++ b/ext/session/session.c @@ -2756,7 +2756,7 @@ static int php_session_rfc1867_callback(unsigned int event, void *event_data, vo ALLOC_INIT_ZVAL(progress->files); array_init(progress->files); - add_assoc_long_ex(progress->data, "start_time", sizeof("start_time"), (long)sapi_get_request_time(TSRMLS_C)); + add_assoc_long_ex(progress->data, "start_time", sizeof("start_time"), (php_int_t)sapi_get_request_time(TSRMLS_C)); add_assoc_long_ex(progress->data, "content_length", sizeof("content_length"), progress->content_length); add_assoc_zval_ex(progress->data, "bytes_processed", sizeof("bytes_processed"), progress->post_bytes_processed); add_assoc_bool_ex(progress->data, "done", sizeof("done"), 0); @@ -2781,7 +2781,7 @@ static int php_session_rfc1867_callback(unsigned int event, void *event_data, vo add_assoc_long_ex(progress->current_file, "error", sizeof("error"), 0); add_assoc_bool_ex(progress->current_file, "done", sizeof("done"), 0); - add_assoc_long_ex(progress->current_file, "start_time", sizeof("start_time"), (long)time(NULL)); + add_assoc_long_ex(progress->current_file, "start_time", sizeof("start_time"), (php_int_t)time(NULL)); add_assoc_zval_ex(progress->current_file, "bytes_processed", sizeof("bytes_processed"), progress->current_file_bytes_processed); add_next_index_zval(progress->files, progress->current_file); diff --git a/ext/session/tests/016.phpt b/ext/session/tests/016.phpt index 0e368e2..82a85d2 100644 --- a/ext/session/tests/016.phpt +++ b/ext/session/tests/016.phpt @@ -22,5 +22,5 @@ session_write_close(); print "I live\n"; ?> --EXPECTF-- -Warning: session_write_close(): Failed to write session data (files). Please verify that the current setting of session.save_path is correct (123;:/really\completely:::/invalid;;,23123;213) in %s on line %d +Warning: session_write_close(): Failed to write session data (files). Please verify that the current setting of session.save_path is correct (123;:/really%scompletely:::/invalid;;,23123;213) in %s on line %d I live diff --git a/ext/session/tests/session_hash_function_basic.phpt b/ext/session/tests/session_hash_function_basic.phpt index 663852d..a9c9215 100644 --- a/ext/session/tests/session_hash_function_basic.phpt +++ b/ext/session/tests/session_hash_function_basic.phpt @@ -43,7 +43,7 @@ bool(true) string(40) "%s" bool(true) -Warning: ini_set(): session.configuration 'session.hash_function' must be existing hash function. none does not exist. in %s/session_hash_function_basic.php on line 17 +Warning: ini_set(): session.configuration 'session.hash_function' must be existing hash function. none does not exist. in %s%esession_hash_function_basic..php on line 17 bool(false) bool(true) bool(true) diff --git a/ext/session/tests/session_save_path_variation2.phpt b/ext/session/tests/session_save_path_variation2.phpt index dff0701..4cf44b7 100644 --- a/ext/session/tests/session_save_path_variation2.phpt +++ b/ext/session/tests/session_save_path_variation2.phpt @@ -32,7 +32,7 @@ ob_end_flush(); *** Testing session_save_path() : variation *** string(5) "/blah" -Warning: session_start(): open(/blah/%s, O_RDWR) failed: No such file or directory (2) in %s on line %d +Warning: session_start(): open(%sblah%e%s, O_RDWR) failed: No such file or directory (2) in %s on line %d bool(true) string(5) "/blah" bool(true) diff --git a/ext/session/tests/session_serializer_name_basic.phpt b/ext/session/tests/session_serializer_name_basic.phpt index ca292dd..b0560dc 100644 --- a/ext/session/tests/session_serializer_name_basic.phpt +++ b/ext/session/tests/session_serializer_name_basic.phpt @@ -30,7 +30,7 @@ string(3) "php" bool(true) bool(true) -Warning: session_serializer_name(): Cannot find serialization handler 'none' in %s/session_serializer_name_basic.php on line 16 +Warning: session_serializer_name(): Cannot find serialization handler 'none' in %s%esession_serializer_name_basic.php on line 16 bool(false) string(10) "php_binary" Done

« previous php.cvs (#74094) next »