Be more clean and use a auto lock, thanks Axel.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42343 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -2587,7 +2587,7 @@ Desktop::_DispatchMessage(int32 code, BPrivate::LinkReceiver& link)
|
|||||||
break;
|
break;
|
||||||
|
|
||||||
BPrivate::LinkSender reply(clientReplyPort);
|
BPrivate::LinkSender reply(clientReplyPort);
|
||||||
LockAllWindows();
|
AutoWriteLocker locker(fWindowLock);
|
||||||
if (MessageForListener(NULL, link, reply) != true) {
|
if (MessageForListener(NULL, link, reply) != true) {
|
||||||
// unhandled message, at least send an error if needed
|
// unhandled message, at least send an error if needed
|
||||||
if (link.NeedsReply()) {
|
if (link.NeedsReply()) {
|
||||||
@@ -2595,7 +2595,6 @@ Desktop::_DispatchMessage(int32 code, BPrivate::LinkReceiver& link)
|
|||||||
reply.Flush();
|
reply.Flush();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
UnlockAllWindows();
|
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user