Handle null length arg correctly in mb_substr() and mb_strcut()
commitdfa78bfb67b83c24d6d89c401013e37b0e14f9ca
authorSara Golemon <sgolemon@fb.com>
Wed, 12 Mar 2014 00:21:43 +0000 (11 17:21 -0700)
committerSara Golemon <sgolemon@fb.com>
Wed, 12 Mar 2014 00:45:33 +0000 (11 17:45 -0700)
treeb2c446b1b599a2fd60176493e8b06ed905f77983
parentc548aec065fd47ec87835841b4f8c52cc9e32f49
Handle null length arg correctly in mb_substr() and mb_strcut()

null should indicate "whole string"

Closes #2016

Reviewed By: @fredemmott

Differential Revision: D1214435
hphp/runtime/ext/ext_mb.cpp
hphp/runtime/ext/ext_mb.h
hphp/system/idl/mb.idl.json
hphp/test/slow/mbstring-github-bug2016.php [new file with mode: 0644]
hphp/test/slow/mbstring-github-bug2016.php.expect [new file with mode: 0644]