File tree 1 file changed +9
-11
lines changed
1 file changed +9
-11
lines changed Original file line number Diff line number Diff line change @@ -94,17 +94,15 @@ impl EncryptedDnsProxyState {
94
94
}
95
95
96
96
fn next_configuration ( & mut self ) -> Option < ProxyConfig > {
97
- if !self . has_tried_xor {
98
- self . has_tried_xor = true ;
99
- if let Some ( xor_config) = self
100
- . configurations
101
- . iter ( )
102
- // prefer obfuscated proxy configurations.
103
- . find ( |config| config. obfuscation . is_some ( ) )
104
- {
105
- self . tried_configurations . insert ( xor_config. clone ( ) ) ;
106
- return Some ( xor_config. clone ( ) ) ;
107
- }
97
+ if let Some ( xor_config) = self
98
+ . configurations
99
+ . diference ( & self . tried_configurations )
100
+ // prefer obfuscated proxy configurations.
101
+ . find ( |config| config. obfuscation . is_some ( ) )
102
+ . cloned ( )
103
+ {
104
+ self . tried_configurations . insert ( xor_config. clone ( ) ) ;
105
+ return Some ( xor_config) ;
108
106
}
109
107
110
108
let config = self
You can’t perform that action at this time.
0 commit comments