diff --git a/uriloader/base/nsDocLoader.cpp b/uriloader/base/nsDocLoader.cpp index 7510dd6b3dd..9ab9f489c3d 100644 --- a/uriloader/base/nsDocLoader.cpp +++ b/uriloader/base/nsDocLoader.cpp @@ -1300,12 +1300,13 @@ void nsDocLoader::FireOnStateChange(nsIWebProgress *aProgress, */ nsCOMPtr listener; PRInt32 count = mListenerInfoList.Count(); + PRInt32 notifyMask = (aStateFlags >> 16) & nsIWebProgress::NOTIFY_STATE_ALL; while (--count >= 0) { nsListenerInfo *info; info = static_cast(mListenerInfoList.SafeElementAt(count)); - if (!info || !(info->mNotifyMask & (aStateFlags >>16))) { + if (!info || !(info->mNotifyMask & notifyMask)) { continue; }