summaryrefslogtreecommitdiff
path: root/ext/session/session.c
diff options
context:
space:
mode:
authorSascha Schumann <sas@php.net>2001-08-03 08:51:53 +0000
committerSascha Schumann <sas@php.net>2001-08-03 08:51:53 +0000
commit60024a469de8a4aa4a5ba23557d5a1eef3d92fa3 (patch)
treefa9f057632230880db587165b34db37b5ef0b6cf /ext/session/session.c
parent7471943c064e93cc9caafda6044e7190a762a477 (diff)
downloadphp-git-60024a469de8a4aa4a5ba23557d5a1eef3d92fa3.tar.gz
Add some casts
Diffstat (limited to 'ext/session/session.c')
-rw-r--r--ext/session/session.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/ext/session/session.c b/ext/session/session.c
index ab491a96b3..6b32d94a86 100644
--- a/ext/session/session.c
+++ b/ext/session/session.c
@@ -287,13 +287,13 @@ PS_SERIALIZER_ENCODE_FUNC(php_binary)
PS_ENCODE_LOOP(
if (key_length > PS_BIN_MAX) continue;
- smart_str_appendc(&buf, key_length);
+ smart_str_appendc(&buf, (unsigned char) key_length);
smart_str_appendl(&buf, key, key_length);
php_var_serialize(&buf, struc, &var_hash);
} else {
if (key_length > PS_BIN_MAX) continue;
- smart_str_appendc(&buf, (key_length & PS_BIN_UNDEF));
+ smart_str_appendc(&buf, (unsigned char) (key_length & PS_BIN_UNDEF));
smart_str_appendl(&buf, key, key_length);
);
@@ -353,7 +353,7 @@ PS_SERIALIZER_ENCODE_FUNC(php)
PS_ENCODE_LOOP(
if (key_length + 1 > MAX_STR) continue;
- smart_str_appendl(&buf, key, key_length);
+ smart_str_appendl(&buf, key, (unsigned char) key_length);
smart_str_appendc(&buf, PS_DELIMITER);
php_var_serialize(&buf, struc, &var_hash);