Bump to Rust 2024
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
[package]
|
||||
name = "imap"
|
||||
version = "0.11.5"
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
resolver = "2"
|
||||
|
||||
[dependencies]
|
||||
@@ -24,7 +24,7 @@ tokio-rustls = { version = "0.26", default-features = false, features = ["ring",
|
||||
parking_lot = "0.12"
|
||||
ahash = { version = "0.8" }
|
||||
md5 = "0.7.0"
|
||||
rand = "0.8.5"
|
||||
rand = "0.9.0"
|
||||
|
||||
|
||||
[features]
|
||||
|
||||
@@ -606,7 +606,7 @@ impl<T: SessionStream> SessionData<T> {
|
||||
if account
|
||||
.prefix
|
||||
.as_ref()
|
||||
.map_or(true, |p| mailbox_name.starts_with(p))
|
||||
.is_none_or( |p| mailbox_name.starts_with(p))
|
||||
{
|
||||
for (mailbox_name_, mailbox_id_) in account.mailbox_names.iter() {
|
||||
if (!is_inbox && mailbox_name_ == mailbox_name)
|
||||
|
||||
@@ -13,14 +13,14 @@ use crate::{
|
||||
use common::listener::SessionStream;
|
||||
use directory::Permission;
|
||||
use imap_proto::{
|
||||
Command, StatusResponse,
|
||||
protocol::{
|
||||
ImapResponse, ProtocolVersion,
|
||||
list::{
|
||||
self, Arguments, Attribute, ChildInfo, ListItem, ReturnOption, SelectionOption, Tag,
|
||||
},
|
||||
ImapResponse, ProtocolVersion,
|
||||
},
|
||||
receiver::Request,
|
||||
Command, StatusResponse,
|
||||
};
|
||||
|
||||
use super::ImapContext;
|
||||
@@ -316,7 +316,7 @@ pub fn matches_pattern(patterns: &[String], mailbox_name: &str) -> bool {
|
||||
'inner: while let Some((pos, &ch)) = pattern_bytes.next() {
|
||||
if ch == b'%' || ch == b'*' {
|
||||
let mut end_pos = pos;
|
||||
while let Some((_, &next_ch)) = pattern_bytes.peek() {
|
||||
while let Some(&(_, &next_ch)) = pattern_bytes.peek() {
|
||||
if next_ch == b'%' || next_ch == b'*' {
|
||||
break;
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user