From c888cdec61b7c3fdf164b15841b6aa148f0148d5 Mon Sep 17 00:00:00 2001 From: MikalaiR Date: Fri, 25 Sep 2015 18:47:53 +0000 Subject: Toaster: crash fix; check in options for enable/disable git-svn-id: http://svn.miranda-ng.org/main/trunk@15443 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- plugins/Toaster/src/services.cpp | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) (limited to 'plugins/Toaster/src/services.cpp') diff --git a/plugins/Toaster/src/services.cpp b/plugins/Toaster/src/services.cpp index 1209ebe0cd..ebfb13b3a5 100644 --- a/plugins/Toaster/src/services.cpp +++ b/plugins/Toaster/src/services.cpp @@ -262,11 +262,8 @@ static INT_PTR ShowMessage(WPARAM wParam, LPARAM lParam) void __stdcall HideAllToasts(void*) { mir_cslock lck(csNotifications); - while (lstNotifications.getCount()) - { - lstNotifications[0].Hide(); - lstNotifications.remove(0); - } + for (int i = 0; i < lstNotifications.getCount(); i++) + lstNotifications[i].Hide(); } void InitServices() -- cgit v1.2.3