Bug 257026 - Stop pref-manager calling observers for prefs it doesn't know (fixes hang when joining channels with URLs in the topic).

ChatZilla only.
r=rginda
This commit is contained in:
silver%warwickcompsoc.co.uk 2004-12-19 22:42:14 +00:00
parent 1a43dc79c0
commit 8aff9aeb07

View File

@ -141,6 +141,10 @@ function pm_removeobserver(observer)
PrefManager.prototype.onPrefChanged =
function pm_prefchanged(prefName, realValue, oldValue)
{
// We're only interested in prefs we actually know about.
if (!(prefName in this.prefRecords))
return;
for (var i = 0; i < this.observers.length; i++)
this.observers[i].onPrefChanged(prefName, realValue, oldValue);
}