mirror of
https://github.com/vanitasvitae/Smack.git
synced 2024-11-22 03:52:06 +01:00
[core] Improve how the selected keys are copied in SmackReactor
This commit is contained in:
parent
844ebbf4c5
commit
9acee05e5e
1 changed files with 2 additions and 3 deletions
|
@ -1,6 +1,6 @@
|
|||
/**
|
||||
*
|
||||
* Copyright 2018-2020 Florian Schmaus
|
||||
* Copyright 2018-2023 Florian Schmaus
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
|
@ -276,8 +276,7 @@ public class SmackReactor {
|
|||
setInterestOpsCancelledKeySafe(selectionKey, 0);
|
||||
}
|
||||
|
||||
selectedKeys = new ArrayList<>(selectedKeySet.size());
|
||||
selectedKeys.addAll(selectedKeySet);
|
||||
selectedKeys = new ArrayList<>(selectedKeySet);
|
||||
selectedKeySet.clear();
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue