Skip to content

Commit

Permalink
Fix NPE raised by HttpHeaders.equalsIgnoreCases() when one of its arg…
Browse files Browse the repository at this point in the history
…uments is null
  • Loading branch information
trustin committed Nov 28, 2013
1 parent 6ade866 commit 313365c
Showing 1 changed file with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1161,6 +1161,10 @@ public static boolean equalsIgnoreCase(CharSequence name1, CharSequence name2) {
return true;
}

if (name1 == null || name2 == null) {
return false;
}

int nameLen = name1.length();
if (nameLen != name2.length()) {
return false;
Expand Down

0 comments on commit 313365c

Please sign in to comment.