[HttpFoundation] Fix an issue caused by php's Bug #66606.

see https://bugs.php.net/bug.php?id=66606 .
Can you refer bug in comment?