| ★ wanayoo — archive 1999 http://cvs.php.net/cvsweb.cgi/functions/imap.c | Nouvelle recherche | Portail wanayoo |

Request diff between arbitrary revisions
cjh: message sequence numbers are always 1 or greater. so let's just return false on invalid input rather than segfaulting.
Careful...
fixed seg fault with reopening a stream, courtesy of Stig Venaas
cjh: in imap_add_body, strncasecmp was being used to test if a part was of type message/rfc822. This caused parts of type message/rfc822-headers to be treated as message/rfc822s, which in turn caused a segfault. Using strcasecmp fixes the problem.
cjh: This fixes a problem in imap_fetchstructure that caused the piece of the returned object that should have had the content-id header of that message part to instead include the content-description header.
chagenbu: The check that was added for (body->CONTENT_MSG_BODY) caused a segfault for me where there hadn't been one before. I'm commenting it out for now, as it apparently didn't fix the problem it was intended to fix either.
fixed small bug
Need a paramdef here.
imap_search() function from Chuck
last test for proper rfc822 date
small change..test for proper cvs mai ldate
===== Chuck Hagenbuch ===== - the \\Draft flag is included in the flags returned by imap_header, etc. - there are two new list functions, imap_getmailboxes() and imap_getsubscribed(). These return arrays of objects, and the objects contain the name of the mailbox, the hierarchy delimiter for that part of the namespace, and the mailbox attributes. These flags are essential for figuring out anything much about mailboxes. - there is a new constant, SA_ALL, that can be passed to imap_status in order to populate all the members of the returned object. - there are now imap_errors() and imap_last_error() functions. imap_errors returns an array containing all of the errors since the page started or since imap_errors() was last called. imap_errors() clears the error stack when it's called. imap_last_error() simply returns the last error that occurred; it does NOT clear the error stack. - imap_alerts() behaves exactly like imap_errors() wrt behavior, but it acts on the alert list. Previously [ALERT] messages were not accessible from PHP; the IMAP spec requires that be passed onto the user. This function allows the script author the option of doing so. Finally, I tried to write an end_request function that would output any errors and alerts that hadn't been gotten with imap_errors/imap_alerts() (alerts at E_NOTICE level, errors at their original level), but imap_end_request() doesn't seem to get called. Is output not allowed from the end_request() function?