Bugs item #1194792, was opened at 2005-05-03 15:18
Message generated for change (Tracker Item Submitted) made by Item Submitter
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=497982&aid=1194792&group_id=61302

Category: None
Group: None
Status: Open
Resolution: None
Priority: 5
Submitted By: Avram Cherry (alannon)
Assigned to: Nobody/Anonymous (nobody)
Summary: SameLinkPredicate needs a null check

Initial Comment:
SameLinkPredicate seems to assume that all links have the same 
attributes, and thus, when the 'given' attributes doesn't contain an 
attribute that the 'found' attribute contains, 
getNamedItem(attributeName) will return null.  
givenAttribute.getValue() then produces a NullPointerException.

the following snippet fixes this problem:

if (givenAttribute == null) {
  return false;
}

I'm rather surprised this hasn't been caught earlier.

----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=497982&aid=1194792&group_id=61302


-------------------------------------------------------
This SF.Net email is sponsored by: NEC IT Guy Games.
Get your fingers limbered up and give it your best shot. 4 great events, 4
opportunities to win big! Highest score wins.NEC IT Guy Games. Play to
win an NEC 61 plasma display. Visit http://www.necitguy.com/?r=20
_______________________________________________
Jwebunit-development mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jwebunit-development

Reply via email to