You are viewing a plain text version of this content. The canonical link for it is here.
Posted to zeta-issues@incubator.apache.org by "Michael Kliewe (JIRA)" <ji...@apache.org> on 2010/12/01 16:09:10 UTC
[jira] Created: (ZETACOMP-28) ezcMailImapTransport fetchFlags regex
does not work with dovecot 2.0
ezcMailImapTransport fetchFlags regex does not work with dovecot 2.0
--------------------------------------------------------------------
Key: ZETACOMP-28
URL: https://issues.apache.org/jira/browse/ZETACOMP-28
Project: Zeta Components
Issue Type: Bug
Components: Mail
Reporter: Michael Kliewe
When connecting to a Dovecot 2.0 imap server I get an empty flag array, because the dovecot seems to return the results in a different order than expected. See this examples:
Dovecot 2.0 Server:
tag1 UID FETCH 1 (FLAGS)
* 1 FETCH (UID 1 FLAGS (\Seen $NotJunk unknown-0))
tag1 OK Fetch completed.
Dovecot 1.2 Server:
tag1 UID FETCH 2 (FLAGS)
* 1 FETCH (FLAGS (\Seen $NotJunk) UID 2)
tag1 OK Fetch completed.
1und1 Server:
tag1 UID FETCH 27134 (FLAGS)
* 15992 FETCH (FLAGS (\Seen $NotJunk) UID 27134)
tag1 OK UID FETCH finished.
The used regex expects first the FLAGS and then the UID information.
preg_match( '/\*\s.*\sFETCH\s\(FLAGS \((.*)\)\sUID\s(.*)\)/U', $response, $matches );
There are 2 possible solutions:
- make the regex variable so that it detects the FLAGS regardless of its position
- change the request to "{$tag} {$uid}FETCH {$ids} (UID FLAGS)" so that the order is always the same and change the regex
affected Version: eZ Components 2009.2.1
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.