2011-02-04 Anders Carlsson <andersca@apple.com>
authorandersca@apple.com <andersca@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 4 Feb 2011 20:45:19 +0000 (20:45 +0000)
committerandersca@apple.com <andersca@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 4 Feb 2011 20:45:19 +0000 (20:45 +0000)
        Reviewed by Maciej Stachowiak.

        Fix a shared memory leak
        https://bugs.webkit.org/show_bug.cgi?id=53800

        Move the send right representing the shared memory.

        * Platform/mac/SharedMemoryMac.cpp:
        (WebKit::SharedMemory::Handle::encode):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@77658 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Source/WebKit2/ChangeLog
Source/WebKit2/Platform/mac/SharedMemoryMac.cpp

index 347fd805a05ec252e462c0d21dbf222c659a8a54..b69e505bbbbe6fd522c0af123933eeb063f4d499 100644 (file)
@@ -1,3 +1,15 @@
+2011-02-04  Anders Carlsson  <andersca@apple.com>
+
+        Reviewed by Maciej Stachowiak.
+
+        Fix a shared memory leak
+        https://bugs.webkit.org/show_bug.cgi?id=53800
+
+        Move the send right representing the shared memory.
+
+        * Platform/mac/SharedMemoryMac.cpp:
+        (WebKit::SharedMemory::Handle::encode):
+
 2011-02-04  Brady Eidson  <beidson@apple.com>
 
         Reviewed by Anders Carlsson.
index dc5bf835f9b73f467e454b14b7e4a4856cc11488..00ead50f635dfd954efa09bfcf7de18de648c2d7 100644 (file)
@@ -57,7 +57,7 @@ bool SharedMemory::Handle::isNull() const
 void SharedMemory::Handle::encode(CoreIPC::ArgumentEncoder* encoder) const
 {
     encoder->encodeUInt64(m_size);
-    encoder->encode(CoreIPC::MachPort(m_port, MACH_MSG_TYPE_COPY_SEND));
+    encoder->encode(CoreIPC::MachPort(m_port, MACH_MSG_TYPE_MOVE_SEND));
     m_port = MACH_PORT_NULL;
 }