Patch to fix bug 563573. r=bent

--HG--
extra : rebase_source : cc7f009be395bfc98ffcce4831e233dee1fa7480
This commit is contained in:
Ben Newman 2010-05-10 18:05:40 -07:00
Родитель 51fd47f445
Коммит ad7c97dbe8
1 изменённых файлов: 6 добавлений и 3 удалений

Просмотреть файл

@ -46,6 +46,7 @@
#include "nsIRunnable.h"
#include "nsStringGlue.h"
#include "nsCOMPtr.h"
#include "nsAutoPtr.h"
// This is needed on some systems to prevent collisions between the symbols
// appearing in xpcom_core and xpcomglue. It may be unnecessary in the future
@ -435,8 +436,10 @@ public:
}
const nsRevocableEventPtr& operator=(T *event) {
Revoke();
mEvent = event;
if (mEvent != event) {
Revoke();
mEvent = event;
}
return *this;
}
@ -462,7 +465,7 @@ private:
nsRevocableEventPtr(const nsRevocableEventPtr&);
nsRevocableEventPtr& operator=(const nsRevocableEventPtr&);
T *mEvent;
nsRefPtr<T> mEvent;
};
#endif // nsThreadUtils_h__