From ecc00cac9a817036cc09de87339f4372abf83f44 Mon Sep 17 00:00:00 2001 From: "brendan%mozilla.org" Date: Sat, 19 Aug 2000 17:07:46 +0000 Subject: [PATCH] Cast away const when freeing JSClass names. --- content/xbl/src/nsXBLBinding.cpp | 2 +- content/xbl/src/nsXBLService.h | 2 +- layout/xbl/src/nsXBLBinding.cpp | 2 +- layout/xbl/src/nsXBLService.h | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/content/xbl/src/nsXBLBinding.cpp b/content/xbl/src/nsXBLBinding.cpp index a723a35b4d3..f2612b68cd9 100644 --- a/content/xbl/src/nsXBLBinding.cpp +++ b/content/xbl/src/nsXBLBinding.cpp @@ -1283,7 +1283,7 @@ nsXBLBinding::InitClass(const nsCString& aClassName, nsIScriptContext* aContext, (nsXBLService::gClassTable)->Remove(&oldKey); // Change the class name and we're done. - nsMemory::Free(c->name); + nsMemory::Free((void*) c->name); c->name = nsXPIDLCString::Copy(aClassName); } diff --git a/content/xbl/src/nsXBLService.h b/content/xbl/src/nsXBLService.h index 52f79633adc..b86ad997fda 100644 --- a/content/xbl/src/nsXBLService.h +++ b/content/xbl/src/nsXBLService.h @@ -129,7 +129,7 @@ private: public: nsXBLJSClass(const nsCString& aClassName); - ~nsXBLJSClass() { nsMemory::Free(name); } + ~nsXBLJSClass() { nsMemory::Free((void*) name); } nsrefcnt Hold() { return ++mRefCnt; } nsrefcnt Drop() { return --mRefCnt ? mRefCnt : Destroy(); } diff --git a/layout/xbl/src/nsXBLBinding.cpp b/layout/xbl/src/nsXBLBinding.cpp index a723a35b4d3..f2612b68cd9 100644 --- a/layout/xbl/src/nsXBLBinding.cpp +++ b/layout/xbl/src/nsXBLBinding.cpp @@ -1283,7 +1283,7 @@ nsXBLBinding::InitClass(const nsCString& aClassName, nsIScriptContext* aContext, (nsXBLService::gClassTable)->Remove(&oldKey); // Change the class name and we're done. - nsMemory::Free(c->name); + nsMemory::Free((void*) c->name); c->name = nsXPIDLCString::Copy(aClassName); } diff --git a/layout/xbl/src/nsXBLService.h b/layout/xbl/src/nsXBLService.h index 52f79633adc..b86ad997fda 100644 --- a/layout/xbl/src/nsXBLService.h +++ b/layout/xbl/src/nsXBLService.h @@ -129,7 +129,7 @@ private: public: nsXBLJSClass(const nsCString& aClassName); - ~nsXBLJSClass() { nsMemory::Free(name); } + ~nsXBLJSClass() { nsMemory::Free((void*) name); } nsrefcnt Hold() { return ++mRefCnt; } nsrefcnt Drop() { return --mRefCnt ? mRefCnt : Destroy(); }