BRoster::ActivateApp() now talks to the Desktop, not the app_server anymore.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14600 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Axel Dörfler
2005-10-31 19:36:19 +00:00
parent 36deda69ba
commit 4f86bb69c5
+13 -1
View File
@@ -785,6 +785,19 @@ BRoster::ActivateApp(team_id team) const
BPrivate::PortLink link(port, replyPort.port);
// We can't use AppServerLink because be_app may be NULL
link.StartMessage(AS_GET_DESKTOP);
link.Attach<port_id>(replyPort.port);
link.Attach<int32>(getuid());
int32 code;
if (link.FlushWithReply(code) != B_OK || code != B_OK)
return B_ERROR;
// we now talk to the desktop
link.Read<port_id>(&port);
link.SetSenderPort(port);
// prepare the message
status_t error = link.StartMessage(AS_ACTIVATE_APP);
if (error != B_OK)
@@ -799,7 +812,6 @@ BRoster::ActivateApp(team_id team) const
return error;
// send it
int32 code;
error = link.FlushWithReply(code);
if (error != B_OK)
return error;