Skip to content

Commit

Permalink
Prevent infinite loop
Browse files Browse the repository at this point in the history
  • Loading branch information
link2xt committed Aug 26, 2024
1 parent 260a697 commit 77c726c
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/imap/client.rs
Original file line number Diff line number Diff line change
Expand Up @@ -239,7 +239,7 @@ impl Client {
}
}
},
_ = delay_set.join_next() => {
_ = delay_set.join_next(), if !delay_set.is_empty() => {
// Delay expired.
//
// Don't do anything other than adding
Expand Down
2 changes: 1 addition & 1 deletion src/smtp/connect.rs
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,7 @@ async fn connect_stream(
}
}
},
_ = delay_set.join_next() => {
_ = delay_set.join_next(), if !delay_set.is_empty() => {
// Delay expired.
//
// Don't do anything other than adding
Expand Down

0 comments on commit 77c726c

Please sign in to comment.