http_build_query(array()) returns NULL, not empty string
| Bug #40009 | http_build_query(array()) returns NULL, not empty string | ||||
|---|---|---|---|---|---|
| Submitted: | 2007-01-03 11:24 UTC | Modified: | 2007-01-03 23:17 UTC | ||
| From: | bugs dot php dot net at chsc dot dk | Assigned: | |||
| Status: | Closed | Package: | URL related | ||
| PHP Version: | 5.2.0 | OS: | Windows | ||
| Private report: | No | CVE-ID: | None | ||
[2007-01-03 11:24 UTC] bugs dot php dot net at chsc dot dk
Description: ------------ http_build_query(array()) returns NULL. According to the documentation, the return type of http_build_query is string. This can be considered a documentation problem, but I think it would be better to change the function so that it always returns a string. Reproduce code: --------------- ./php.exe -r "echo gettype(http_build_query(array()));" Expected result: ---------------- string Actual result: -------------- NULL
Patches
Pull Requests
History
AllCommentsChangesGit/SVN commits
[2007-01-03 23:17 UTC] iliaa@php.net