Hopefully fixed the build when not using Message4. As Message4 works well and is less broken than the older implementation we should maybe switch to it completely.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@16461 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Michael Lotz 2006-02-18 17:25:58 +00:00
parent 9847757f59
commit 38b52de937

View File

@ -1171,6 +1171,7 @@ BLooper::ConvertToMessage(void *buffer, int32 code)
return NULL;
BMessage *message = new BMessage();
#ifdef USING_MESSAGE4
if (code == kPortMessageCodeByArea) {
BMessage::Private messagePrivate(message);
if (messagePrivate.Reference((BMessage::message_header *)buffer) != B_OK) {
@ -1178,12 +1179,15 @@ BLooper::ConvertToMessage(void *buffer, int32 code)
delete message;
message = NULL;
}
} else {
if (message->Unflatten((const char *)buffer) != B_OK) {
PRINT(("BLooper::ConvertToMessage(): unflattening message failed\n"));
delete message;
message = NULL;
}
return message;
}
#endif
if (message->Unflatten((const char *)buffer) != B_OK) {
PRINT(("BLooper::ConvertToMessage(): unflattening message failed\n"));
delete message;
message = NULL;
}
PRINT(("BLooper::ConvertToMessage(): %p\n", message));