Title: [209876] trunk/Source/WebKit2
- Revision
- 209876
- Author
- ander...@apple.com
- Date
- 2016-12-15 14:48:10 -0800 (Thu, 15 Dec 2016)
Log Message
Add more mach_msg logging instrumentation
https://bugs.webkit.org/show_bug.cgi?id=165914
Reviewed by Darin Adler.
* Platform/IPC/mac/ConnectionMac.mm:
(IPC::Connection::sendMessage):
(IPC::Connection::sendOutgoingMessage):
* Platform/IPC/mac/MachMessage.h:
(IPC::MachMessage::messageName):
(IPC::MachMessage::setMessageName):
Modified Paths
Diff
Modified: trunk/Source/WebKit2/ChangeLog (209875 => 209876)
--- trunk/Source/WebKit2/ChangeLog 2016-12-15 22:12:21 UTC (rev 209875)
+++ trunk/Source/WebKit2/ChangeLog 2016-12-15 22:48:10 UTC (rev 209876)
@@ -1,3 +1,17 @@
+2016-12-15 Anders Carlsson <ander...@apple.com>
+
+ Add more mach_msg logging instrumentation
+ https://bugs.webkit.org/show_bug.cgi?id=165914
+
+ Reviewed by Darin Adler.
+
+ * Platform/IPC/mac/ConnectionMac.mm:
+ (IPC::Connection::sendMessage):
+ (IPC::Connection::sendOutgoingMessage):
+ * Platform/IPC/mac/MachMessage.h:
+ (IPC::MachMessage::messageName):
+ (IPC::MachMessage::setMessageName):
+
2016-12-15 Konstantin Tokarev <annu...@yandex.ru>
Added missing override and final specifiers
Modified: trunk/Source/WebKit2/Platform/IPC/mac/ConnectionMac.mm (209875 => 209876)
--- trunk/Source/WebKit2/Platform/IPC/mac/ConnectionMac.mm 2016-12-15 22:12:21 UTC (rev 209875)
+++ trunk/Source/WebKit2/Platform/IPC/mac/ConnectionMac.mm 2016-12-15 22:48:10 UTC (rev 209876)
@@ -283,7 +283,7 @@
return false;
default:
- WKSetCrashReportApplicationSpecificInformation((CFStringRef)[NSString stringWithFormat:@"Unhandled error code %x", kr]);
+ WKSetCrashReportApplicationSpecificInformation((CFStringRef)[NSString stringWithFormat:@"Unhandled error code %x, message '%@'", kr, message->messageName()]);
CRASH();
}
}
@@ -318,6 +318,7 @@
}
auto message = MachMessage::create(messageSize);
+ message->setMessageName((__bridge CFStringRef)[NSString stringWithFormat:@"%s:%s:", encoder->messageReceiverName().toString().data(), encoder->messageName().toString().data()]);
bool isComplex = (numberOfPortDescriptors + numberOfOOLMemoryDescriptors) > 0;
Modified: trunk/Source/WebKit2/Platform/IPC/mac/MachMessage.h (209875 => 209876)
--- trunk/Source/WebKit2/Platform/IPC/mac/MachMessage.h 2016-12-15 22:12:21 UTC (rev 209875)
+++ trunk/Source/WebKit2/Platform/IPC/mac/MachMessage.h 2016-12-15 22:48:10 UTC (rev 209876)
@@ -26,6 +26,7 @@
#pragma once
#include <memory>
+#include <wtf/RetainPtr.h>
namespace IPC {
@@ -42,9 +43,13 @@
void leakDescriptors();
+ CFStringRef messageName() const { return m_messageName.get(); }
+ void setMessageName(CFStringRef messageName) { m_messageName = messageName; }
+
private:
explicit MachMessage(size_t);
+ RetainPtr<CFStringRef> m_messageName;
size_t m_size;
bool m_shouldFreeDescriptors;
uint8_t m_buffer[0];
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes