Bug 946998 - Initialize UDPSocketParent pointer to nullptr. r=jduell
authorChris Peterson <cpeterson@mozilla.com>
Thu, 05 Dec 2013 15:41:46 -0800
changeset 159479 b372181af8e76191b5202590cb66cd3d822d3bbd
parent 159478 97d17b777f684ce75022586c71a98bc8b178802e
child 159480 7713c80c1028137688900d06320e2c4885654186
push id25796
push usercbook@mozilla.com
push dateMon, 09 Dec 2013 08:03:01 +0000
treeherdermozilla-central@7e19e0662879 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersjduell
bugs946998
milestone28.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 946998 - Initialize UDPSocketParent pointer to nullptr. r=jduell
netwerk/ipc/NeckoParent.cpp
--- a/netwerk/ipc/NeckoParent.cpp
+++ b/netwerk/ipc/NeckoParent.cpp
@@ -378,17 +378,17 @@ NeckoParent::DeallocPTCPServerSocketPare
   return true;
 }
 
 PUDPSocketParent*
 NeckoParent::AllocPUDPSocketParent(const nsCString& aHost,
                                    const uint16_t& aPort,
                                    const nsCString& aFilter)
 {
-  UDPSocketParent* p;
+  UDPSocketParent* p = nullptr;
 
   // Only allow socket if it specifies a valid packet filter.
   nsAutoCString contractId(NS_NETWORK_UDP_SOCKET_FILTER_HANDLER_PREFIX);
   contractId.Append(aFilter);
 
   if (!aFilter.IsEmpty()) {
     nsCOMPtr<nsIUDPSocketFilterHandler> filterHandler =
       do_GetService(contractId.get());