Skip to content

Commit

Permalink
oxcmail: reinstate read requests for non-IPM.Schedule messages
Browse files Browse the repository at this point in the history
PR_SENT_REPR is only useful when it's _not_ a meeting request.

Fixes: gromox-2.0-59-g66fd2ea3f
  • Loading branch information
jengelh committed Oct 30, 2023
1 parent b13e1bf commit f18ba74
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 2 deletions.
8 changes: 8 additions & 0 deletions doc/changelog.rst
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
Development 2.17.2
==================

Fixes:

* oxcmail: reinstate read requests for non-IPM.Schedule messages


Gromox 2.16 (2023-10-29)
========================

Expand Down
9 changes: 7 additions & 2 deletions lib/mapi/oxcmail.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3485,6 +3485,7 @@ static bool oxcmail_export_fromsender(const MESSAGE_CONTENT *pmsg,
static bool oxcmail_export_receiptto(const MESSAGE_CONTENT *pmsg,
const char *cset, EXT_BUFFER_ALLOC alloc, MIME *phead, bool sched)
{
/* For DSN (DR (NDR too?)) & MDN */
char tmp_field[MIME_FIELD_LEN];
auto flag = pmsg->proplist.get<uint8_t>(PR_ORIGINATOR_DELIVERY_REPORT_REQUESTED);
if (flag == nullptr || *flag == 0)
Expand All @@ -3495,7 +3496,7 @@ static bool oxcmail_export_receiptto(const MESSAGE_CONTENT *pmsg,
else if (oxcmail_export_address(pmsg, alloc, tags_sender,
cset, tmp_field, std::size(tmp_field)))
/* ok */;
else if (sched && oxcmail_export_address(pmsg, alloc, tags_sent_repr,
else if (!sched && oxcmail_export_address(pmsg, alloc, tags_sent_repr,
cset, tmp_field, std::size(tmp_field)))
/* ok */;
else
Expand All @@ -3506,14 +3507,18 @@ static bool oxcmail_export_receiptto(const MESSAGE_CONTENT *pmsg,
static bool oxcmail_export_receiptflg(const MESSAGE_CONTENT *pmsg,
const char *cset, EXT_BUFFER_ALLOC alloc, MIME *phead, bool sched)
{
/* For read requests */
char tmp_field[MIME_FIELD_LEN];
auto flag = pmsg->proplist.get<uint8_t>(PR_READ_RECEIPT_REQUESTED);
if (flag == nullptr || *flag == 0)
return true;
if (oxcmail_export_address(pmsg, alloc, tags_read_rcpt,
cset, tmp_field, std::size(tmp_field)))
/* ok */;
else if (sched && oxcmail_export_address(pmsg, alloc, tags_sent_repr,
else if (oxcmail_export_address(pmsg, alloc, tags_sender,
cset, tmp_field, std::size(tmp_field)))
/* ok */;
else if (!sched && oxcmail_export_address(pmsg, alloc, tags_sent_repr,
cset, tmp_field, std::size(tmp_field)))
/* ok */;
else
Expand Down

0 comments on commit f18ba74

Please sign in to comment.