ProcessController: Fix memory leak.
This commit is contained in:
@@ -102,10 +102,8 @@ PCApplication::ReadyToRun()
|
|||||||
int32 count = list.CountItems();
|
int32 count = list.CountItems();
|
||||||
if (count > 1) {
|
if (count > 1) {
|
||||||
for (int32 i = 0; i < count - 1; i++) {
|
for (int32 i = 0; i < count - 1; i++) {
|
||||||
BMessenger* otherme = new BMessenger(NULL, (addr_t)list.ItemAt(i));
|
BMessenger otherme(NULL, (addr_t)list.ItemAt(i));
|
||||||
BMessage* message = new BMessage(B_QUIT_REQUESTED);
|
otherme.SendMessage(B_QUIT_REQUESTED);
|
||||||
otherme->SendMessage(message);
|
|
||||||
delete otherme;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user