Edit report at https://bugs.php.net/bug.php?id=65155&edit=1
ID: 65155 Updated by: yohg...@php.net Reported by: yohgaki at ohgaki dot net Summary: hex2bin() should behave consistent -Status: Assigned +Status: Open Type: Feature/Change Request Package: *General Issues Operating System: any PHP Version: 5.4Git-2013-06-28 (Git) Assigned To: yohgaki Block user comment: N Private report: N Previous Comments: ------------------------------------------------------------------------ [2013-06-28 01:50:12] yohgaki at ohgaki dot net Description: ------------ hex2bin() returns false for invalid inputs. However, it raise E_WARNING and return FALSE for invalid length, but it simply returns FALSE for bad chars. Solution: Add E_WARING or remove them. Since hex2bin() is not supposed to handle external input for most cases, Adding E_WARNING would be nicer than removing. ------------------------------------------------------------------------ -- Edit this bug report at https://bugs.php.net/bug.php?id=65155&edit=1