summaryrefslogtreecommitdiff
path: root/src/core/stdautoaway
diff options
context:
space:
mode:
Diffstat (limited to 'src/core/stdautoaway')
-rw-r--r--src/core/stdautoaway/src/autoaway.cpp7
1 files changed, 1 insertions, 6 deletions
diff --git a/src/core/stdautoaway/src/autoaway.cpp b/src/core/stdautoaway/src/autoaway.cpp
index 27531d2b2b..af0a60e441 100644
--- a/src/core/stdautoaway/src/autoaway.cpp
+++ b/src/core/stdautoaway/src/autoaway.cpp
@@ -57,12 +57,7 @@ static int AutoAwayEvent(WPARAM, LPARAM lParam)
if (mii.aaStatus == 0)
return 0;
- int numAccounts;
- PROTOACCOUNT** accounts;
- Proto_EnumAccounts(&numAccounts, &accounts);
-
- for (int i = 0; i < numAccounts; i++) {
- PROTOACCOUNT *pa = accounts[i];
+ for (auto &pa : Accounts()) {
if (!pa->IsEnabled() || pa->IsLocked())
continue;