From ea2e039efd239629a01055d270cf64b84ec54419 Mon Sep 17 00:00:00 2001 From: Ehsan Akhgari Date: Thu, 8 Jan 2015 10:13:01 -0500 Subject: [PATCH] Bug 1119256 - Mark virtual overridden functions as MOZ_OVERRIDE in netwerk; r=jduell --- netwerk/sctp/datachannel/DataChannel.cpp | 2 +- netwerk/streamconv/test/Converters.h | 4 ++-- netwerk/streamconv/test/TestStreamConv.cpp | 6 +++--- netwerk/test/TestCallbacks.cpp | 2 +- netwerk/test/TestCommon.h | 2 +- netwerk/test/TestDNS.cpp | 2 +- netwerk/test/TestProtocols.cpp | 2 +- 7 files changed, 10 insertions(+), 10 deletions(-) diff --git a/netwerk/sctp/datachannel/DataChannel.cpp b/netwerk/sctp/datachannel/DataChannel.cpp index ea85f16bd9754..e17e650821bdd 100644 --- a/netwerk/sctp/datachannel/DataChannel.cpp +++ b/netwerk/sctp/datachannel/DataChannel.cpp @@ -122,7 +122,7 @@ class DataChannelShutdown : public nsIObserver public: NS_IMETHODIMP Observe(nsISupports* aSubject, const char* aTopic, - const char16_t* aData) { + const char16_t* aData) MOZ_OVERRIDE { if (strcmp(aTopic, "profile-change-net-teardown") == 0) { LOG(("Shutting down SCTP")); if (sctp_initialized) { diff --git a/netwerk/streamconv/test/Converters.h b/netwerk/streamconv/test/Converters.h index 7b96b344fc17f..1ee59fd68f18c 100644 --- a/netwerk/streamconv/test/Converters.h +++ b/netwerk/streamconv/test/Converters.h @@ -29,11 +29,11 @@ class TestConverter : public nsIStreamConverter { // nsIStreamConverter methods NS_IMETHOD Convert(nsIInputStream *aFromStream, const char *aFromType, - const char *aToType, nsISupports *ctxt, nsIInputStream **_retval); + const char *aToType, nsISupports *ctxt, nsIInputStream **_retval) MOZ_OVERRIDE; NS_IMETHOD AsyncConvertData(const char *aFromType, const char *aToType, - nsIStreamListener *aListener, nsISupports *ctxt); + nsIStreamListener *aListener, nsISupports *ctxt) MOZ_OVERRIDE; // member data nsCOMPtr mListener; diff --git a/netwerk/streamconv/test/TestStreamConv.cpp b/netwerk/streamconv/test/TestStreamConv.cpp index 804b3b08b9831..749d127ab6154 100644 --- a/netwerk/streamconv/test/TestStreamConv.cpp +++ b/netwerk/streamconv/test/TestStreamConv.cpp @@ -57,7 +57,7 @@ class EndListener MOZ_FINAL : public nsIStreamListener { // nsIStreamListener method NS_IMETHOD OnDataAvailable(nsIRequest* request, nsISupports *ctxt, nsIInputStream *inStr, - uint64_t sourceOffset, uint32_t count) + uint64_t sourceOffset, uint32_t count) MOZ_OVERRIDE { nsresult rv; uint32_t read; @@ -81,10 +81,10 @@ class EndListener MOZ_FINAL : public nsIStreamListener { } // nsIRequestObserver methods - NS_IMETHOD OnStartRequest(nsIRequest* request, nsISupports *ctxt) { return NS_OK; } + NS_IMETHOD OnStartRequest(nsIRequest* request, nsISupports *ctxt) MOZ_OVERRIDE { return NS_OK; } NS_IMETHOD OnStopRequest(nsIRequest* request, nsISupports *ctxt, - nsresult aStatus) { return NS_OK; } + nsresult aStatus) MOZ_OVERRIDE { return NS_OK; } }; NS_IMPL_ISUPPORTS(EndListener, diff --git a/netwerk/test/TestCallbacks.cpp b/netwerk/test/TestCallbacks.cpp index 4a845a34e6db8..21a21a6b4093e 100644 --- a/netwerk/test/TestCallbacks.cpp +++ b/netwerk/test/TestCallbacks.cpp @@ -52,7 +52,7 @@ class ConsumerContext MOZ_FINAL : public nsIEquals { ConsumerContext() { } - NS_IMETHOD Equals(void *aPtr, bool *_retval) { + NS_IMETHOD Equals(void *aPtr, bool *_retval) MOZ_OVERRIDE { *_retval = true; if (aPtr != this) *_retval = false; return NS_OK; diff --git a/netwerk/test/TestCommon.h b/netwerk/test/TestCommon.h index d79748df0d52b..d713b0eaa65a4 100644 --- a/netwerk/test/TestCommon.h +++ b/netwerk/test/TestCommon.h @@ -22,7 +22,7 @@ class nsQuitPumpingEvent MOZ_FINAL : public nsIRunnable { ~nsQuitPumpingEvent() {} public: NS_DECL_THREADSAFE_ISUPPORTS - NS_IMETHOD Run() { + NS_IMETHOD Run() MOZ_OVERRIDE { gKeepPumpingEvents = false; return NS_OK; } diff --git a/netwerk/test/TestDNS.cpp b/netwerk/test/TestDNS.cpp index afcb14ea4b481..f5dffb91e6b74 100644 --- a/netwerk/test/TestDNS.cpp +++ b/netwerk/test/TestDNS.cpp @@ -30,7 +30,7 @@ class myDNSListener : public nsIDNSListener NS_IMETHOD OnLookupComplete(nsICancelable *request, nsIDNSRecord *rec, - nsresult status) + nsresult status) MOZ_OVERRIDE { printf("%d: OnLookupComplete called [host=%s status=%x rec=%p]\n", mIndex, mHost.get(), static_cast(status), (void*)rec); diff --git a/netwerk/test/TestProtocols.cpp b/netwerk/test/TestProtocols.cpp index a707c5be5262d..17e07040a1fc8 100644 --- a/netwerk/test/TestProtocols.cpp +++ b/netwerk/test/TestProtocols.cpp @@ -573,7 +573,7 @@ class NotificationCallbacks MOZ_FINAL : public nsIInterfaceRequestor { NotificationCallbacks() { } - NS_IMETHOD GetInterface(const nsIID& iid, void* *result) { + NS_IMETHOD GetInterface(const nsIID& iid, void* *result) MOZ_OVERRIDE { nsresult rv = NS_ERROR_FAILURE; if (iid.Equals(NS_GET_IID(nsIChannelEventSink))) {