Bug 758992 - Make the classes which use the XPCOM nsISupports implementation macros final, to avoid the warning about deleting using a pointer to a base class with virtual functions and no virtual dtor (more intl parts); blanket-r=bzbarsky
authorEhsan Akhgari <ehsan@mozilla.com>
Thu, 26 Jul 2012 15:17:40 -0400
changeset 100632 e76fcfc703161873c9b7cc9293a1ccfc899fb32d
parent 100631 fdd99385caaf4606f3398066d786b35db810c131
child 100633 221933d494d3080905141c88e744511323f3ffd3
push id1
push userroot
push dateMon, 20 Oct 2014 17:29:22 +0000
bugs758992
milestone17.0a1
Bug 758992 - Make the classes which use the XPCOM nsISupports implementation macros final, to avoid the warning about deleting using a pointer to a base class with virtual functions and no virtual dtor (more intl parts); blanket-r=bzbarsky
intl/locale/src/unix/nsCollationUnix.h
netwerk/protocol/http/nsHttpChannelAuthProvider.h
--- a/intl/locale/src/unix/nsCollationUnix.h
+++ b/intl/locale/src/unix/nsCollationUnix.h
@@ -6,20 +6,21 @@
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 #ifndef nsCollationUnix_h__
 #define nsCollationUnix_h__
 
 
 #include "nsICollation.h"
 #include "nsCollation.h"  // static library
 #include "plstr.h"
+#include "mozilla/Attributes.h"
 
 
 
-class nsCollationUnix : public nsICollation {
+class nsCollationUnix MOZ_FINAL : public nsICollation {
 
 protected:
   nsCollation   *mCollation;
   nsCString     mLocale;
   nsCString     mSavedLocale;
   bool          mUseCodePointOrder;
 
   void DoSetLocale();
--- a/netwerk/protocol/http/nsHttpChannelAuthProvider.h
+++ b/netwerk/protocol/http/nsHttpChannelAuthProvider.h
@@ -12,16 +12,17 @@
 #include "nsIAuthPromptCallback.h"
 #include "nsString.h"
 #include "nsCOMPtr.h"
 #include "nsIHttpAuthenticableChannel.h"
 #include "nsIURI.h"
 #include "nsHttpAuthCache.h"
 #include "nsProxyInfo.h"
 #include "nsIDNSListener.h"
+#include "mozilla/Attributes.h"
 
 class nsIHttpAuthenticator;
 
 class nsHttpChannelAuthProvider : public nsIHttpChannelAuthProvider
                                 , public nsIAuthPromptCallback
 {
 public:
     NS_DECL_ISUPPORTS
@@ -146,17 +147,17 @@ private:
     // response. Used in OnAuthAvailable and OnAuthCancelled callbacks.
     PRUint32                          mProxyAuth                : 1;
     PRUint32                          mTriedProxyAuth           : 1;
     PRUint32                          mTriedHostAuth            : 1;
     PRUint32                          mSuppressDefensiveAuth    : 1;
     PRUint32                          mResolvedHost             : 1;
 
     // define a separate threadsafe class for use with the DNS callback
-    class DNSCallback : public nsIDNSListener
+    class DNSCallback MOZ_FINAL : public nsIDNSListener
     {
         NS_DECL_ISUPPORTS
         NS_DECL_NSIDNSLISTENER
 
         DNSCallback(nsHttpChannelAuthProvider *authProvider)
             : mAuthProvider(authProvider)
         { }