don't pointlessly load near-side new messages when expiring

we don't count them towards the total anyway (as they are unpaired).
This commit is contained in:
Oswald Buddenhagen 2022-02-18 18:48:06 +01:00
parent fe4e478e95
commit ef43021f26

View File

@ -787,7 +787,7 @@ box_opened2( sync_vars_t *svars, int t )
// but it's more natural to treat it as read-only in that case. // but it's more natural to treat it as read-only in that case.
// OP_RENEW makes sense only for legacy S_SKIPPED entries. // OP_RENEW makes sense only for legacy S_SKIPPED entries.
if ((chan->ops[N] & (OP_NEW|OP_RENEW|OP_FLAGS)) && chan->max_messages) if ((chan->ops[N] & (OP_NEW|OP_RENEW|OP_FLAGS)) && chan->max_messages)
opts[N] |= OPEN_OLD|OPEN_NEW|OPEN_FLAGS; opts[N] |= OPEN_OLD | OPEN_FLAGS;
svars->opts[F] = svars->drv[F]->prepare_load_box( ctx[F], opts[F] ); svars->opts[F] = svars->drv[F]->prepare_load_box( ctx[F], opts[F] );
svars->opts[N] = svars->drv[N]->prepare_load_box( ctx[N], opts[N] ); svars->opts[N] = svars->drv[N]->prepare_load_box( ctx[N], opts[N] );