You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@hc.apache.org by "Oleg Kalnichevski (JIRA)" <ji...@apache.org> on 2016/08/13 19:20:20 UTC
[jira] [Resolved] (HTTPCLIENT-1761) Missing null check in parse
method
[ https://issues.apache.org/jira/browse/HTTPCLIENT-1761?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Oleg Kalnichevski resolved HTTPCLIENT-1761.
-------------------------------------------
Resolution: Duplicate
Fix Version/s: 4.5.3
> Missing null check in parse method
> ----------------------------------
>
> Key: HTTPCLIENT-1761
> URL: https://issues.apache.org/jira/browse/HTTPCLIENT-1761
> Project: HttpComponents HttpClient
> Issue Type: Bug
> Affects Versions: 4.4.1, 4.5, 4.5.1, 4.5.2
> Reporter: Thomas Feiner
> Fix For: 4.5.3
>
> Attachments: HTTPCLIENT-1761.patch
>
>
> While in org.apache.http.client.utils.URLEncodedUtils the method
> {code}
> public static List<NameValuePair> parse(String s, Charset charset, char... separators)
> {code}
> has a null check for String "s", this method has no null check:
> {code}
> public static List<NameValuePair> parse(String s, Charset charset)
> {code}
> For consistency and backward compatibility reasons I recommend adding a null check there.
> Furthermore I would delegate to the method with separators:
> {code}
> public static List<NameValuePair> parse(String s, Charset charset) {
> return URLEncodedUtils.parse(s, charset, '&', ';');
> }
> {code}
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@hc.apache.org
For additional commands, e-mail: dev-help@hc.apache.org