diff options
author | Sascha Schumann <sas@php.net> | 2002-10-03 15:39:29 +0000 |
---|---|---|
committer | Sascha Schumann <sas@php.net> | 2002-10-03 15:39:29 +0000 |
commit | d4e1ac6c26f1ef9b82fb4810e93af3debfb15bbd (patch) | |
tree | 8b0190cfd3d59d882394b0da1f26f938ba4001f9 /ext/session | |
parent | 5fe046c4c3ac291d21e67b4350f533a005b771e6 (diff) | |
download | php-git-d4e1ac6c26f1ef9b82fb4810e93af3debfb15bbd.tar.gz |
Mini test cases for fixed segfaults
Diffstat (limited to 'ext/session')
-rw-r--r-- | ext/session/tests/010.phpt | 19 | ||||
-rw-r--r-- | ext/session/tests/011.phpt | 20 |
2 files changed, 39 insertions, 0 deletions
diff --git a/ext/session/tests/010.phpt b/ext/session/tests/010.phpt new file mode 100644 index 0000000000..08b97574c6 --- /dev/null +++ b/ext/session/tests/010.phpt @@ -0,0 +1,19 @@ +--TEST-- +$session_array = explode(";", session_encode()); should not segfault. +--SKIPIF-- +<?php include('skipif.inc'); ?> +--INI-- +session.use_cookies=0 +session.cache_limiter= +register_globals=0 +session.bug_compat_42=1 +session.bug_compat_warn=0 +--FILE-- +<?php +error_reporting(E_ALL & ~E_NOTICE); + +$session_array = explode(";", @session_encode()); +print "I live\n"; +?> +--EXPECT-- +I live diff --git a/ext/session/tests/011.phpt b/ext/session/tests/011.phpt new file mode 100644 index 0000000000..d6b6632779 --- /dev/null +++ b/ext/session/tests/011.phpt @@ -0,0 +1,20 @@ +--TEST-- +session_decode(); should not segfault. +--SKIPIF-- +<?php include('skipif.inc'); ?> +--INI-- +session.use_cookies=0 +session.cache_limiter= +register_globals=0 +session.bug_compat_42=1 +session.bug_compat_warn=0 +--FILE-- +<?php +error_reporting(E_ALL & ~E_NOTICE); + +@session_decode("garbage data and no session started"); +@session_decode("userid|s:5:\"mazen\";chatRoom|s:1:\"1\";"); +print "I live\n"; +?> +--EXPECT-- +I live |