com php-src: Merge remote-tracking branch 'origin/PHP-5.6' into str_size_and_int64_56_backport: ext/json/ json.c ext/json/php_json.h ext/pgsql/pgsql.c
| From: | Anatol Belski | Date: | Mon, 17 Feb 2014 11:17:04 +0000 |
| Subject: | com php-src: Merge remote-tracking branch 'origin/PHP-5.6' into str_size_and_int64_56_backport: ext/json/ json.c ext/json/php_json.h ext/pgsql/pgsql.c | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-76066@lists.php.net to get a copy of this message | ||
Commit: 4dd4f728ce1947f3e10aebd5284eb6e80313ed3c
Author: Anatol Belski <ab@php.net> Mon, 17 Feb 2014 12:17:04 +0100
Parents: 463b4505959879cb67556156b427e2da319bf21f 0bc96ef3cc8aedee17d3ab389ee37e90d2ce4d20
Branches: str_size_and_int64_56_backport
Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=4dd4f728ce1947f3e10aebd5284eb6e80313ed3c
Log:
Merge remote-tracking branch 'origin/PHP-5.6' into str_size_and_int64_56_backport
Conflicts:
ext/json/php_json.h
Changed paths:
MM ext/json/json.c
MM ext/json/php_json.h
MM ext/pgsql/pgsql.c
Diff:
diff --cc ext/json/php_json.h
index 2317207,e00de6a..1a62762
--- a/ext/json/php_json.h
+++ b/ext/json/php_json.h
@@@ -49,9 -49,9 +49,9 @@@ ZEND_END_MODULE_GLOBALS(json
# define JSON_G(v) (json_globals.v)
#endif
-PHP_JSON_API void php_json_encode(smart_str *buf, zval *val, int options TSRMLS_DC);
-PHP_JSON_API void php_json_decode_ex(zval *return_value, char *str, int str_len, int options, long
depth TSRMLS_DC);
+PHP_JSON_API void php_json_encode(smart_str *buf, zval *val, php_int_t options TSRMLS_DC);
+PHP_JSON_API void php_json_decode_ex(zval *return_value, char *str, php_size_t str_len, php_int_t
options, php_int_t depth TSRMLS_DC);
- extern zend_class_entry *php_json_serializable_ce;
+ extern PHP_JSON_API zend_class_entry *php_json_serializable_ce;
/* json_encode() options */
diff --cc ext/pgsql/pgsql.c
index f37e78b,bd9a3f6..6c98345
--- a/ext/pgsql/pgsql.c
+++ b/ext/pgsql/pgsql.c
@@@ -5284,32 -5252,20 +5284,20 @@@ PHP_PGSQL_API int php_pgsql_meta_data(P
/* pg_type.typname */
add_assoc_string(elem, "type", PQgetvalue(pg_result,i,2), 1);
/* pg_attribute.attlen */
- add_assoc_long(elem, "len", atoi(PQgetvalue(pg_result,i,3)));
+ add_assoc_int(elem, "len", atoi(PQgetvalue(pg_result,i,3)));
/* pg_attribute.attnonull */
- !strcmp(PQgetvalue(pg_result,i,4), "t") ?
- add_assoc_bool(elem, "not null", 1) :
- add_assoc_bool(elem, "not null", 0);
+ add_assoc_bool(elem, "not null", !strcmp(PQgetvalue(pg_result,i,4), "t"));
/* pg_attribute.atthasdef */
- !strcmp(PQgetvalue(pg_result,i,5), "t") ?
- add_assoc_bool(elem, "has default", 1) :
- add_assoc_bool(elem, "has default", 0);
+ add_assoc_bool(elem, "has default", !strcmp(PQgetvalue(pg_result,i,5),
"t"));
/* pg_attribute.attndims */
- add_assoc_long(elem, "array dims", atoi(PQgetvalue(pg_result,i,6)));
+ add_assoc_int(elem, "array dims", atoi(PQgetvalue(pg_result,i,6)));
/* pg_type.typtype */
- !strcmp(PQgetvalue(pg_result,i,7), "e") ?
- add_assoc_bool(elem, "is enum", 1) :
- add_assoc_bool(elem, "is enum", 0);
+ add_assoc_bool(elem, "is enum", !strcmp(PQgetvalue(pg_result,i,7), "e"));
if (extended) {
/* pg_type.typtype */
- !strcmp(PQgetvalue(pg_result,i,7), "b") ?
- add_assoc_bool(elem, "is base", 1) :
- add_assoc_bool(elem, "is base", 0);
- !strcmp(PQgetvalue(pg_result,i,7), "c") ?
- add_assoc_bool(elem, "is composite", 1) :
- add_assoc_bool(elem, "is composite", 0);
- !strcmp(PQgetvalue(pg_result,i,7), "p") ?
- add_assoc_bool(elem, "is pesudo", 1) :
- add_assoc_bool(elem, "is pesudo", 0);
+ add_assoc_bool(elem, "is base", !strcmp(PQgetvalue(pg_result,i,7), "b"));
+ add_assoc_bool(elem, "is composite", !strcmp(PQgetvalue(pg_result,i,7),
"c"));
+ add_assoc_bool(elem, "is pesudo", !strcmp(PQgetvalue(pg_result,i,7), "p"));
/* pg_description.description */
add_assoc_string(elem, "description", PQgetvalue(pg_result,i,8), 1);
}