Add quotes for some commands to support mailbox with whitespace#127
Merged
link2xt merged 2 commits intochatmail:mainfrom Feb 6, 2026
Merged
Add quotes for some commands to support mailbox with whitespace#127link2xt merged 2 commits intochatmail:mainfrom
link2xt merged 2 commits intochatmail:mainfrom
Conversation
iequidoo
reviewed
Jan 26, 2026
Contributor
Author
|
Lines 2142 to 2164 in 15f80ea Also, this commit will make fail the test due to line 2154 generate expected command without quotes and line 2160 asserts that. Lines 2012 to 2026 in 15f80ea Just adding quote to line 2021 is not fit in because Line 2154 and Line 2158 shares the query.I think the best solution for this is not to construct the expected command in Line 2154 but construct command by each place(like line 2021) and pass into generic_with_uid function.Is this looks good or can you suggest other option? |
Contributor
Author
|
I rewrite generic_copy function as same as how mv operation does, now test passes |
link2xt
approved these changes
Feb 6, 2026
Contributor
|
Thanks! I merged it as is. As for I will tag a release somewhere in a few days. |
Contributor
Author
|
While I was taking vacation for few days, I made lots of thinking for |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
For current state of project, it sends raw data as:
async-imap/src/client.rs
Lines 839 to 843 in 15f80ea
This works well for most cases but not with mailbox with whitespace.
whitespace is separator for argument on IMAP protocol, so this can lead undefined behavior(or not expected error).
This PR adds quotes for all COPY, MOVE, LIST, LSUB mailbox querying.
I am working with icloud mail which seems just ignore if whitespace exists on create command but I am not sure is this standard action.
Thanks for wonderful project :)