Lines Matching defs:_mail
124 struct mail *_mail = context;
126 MAIL_CRYPT_USER_CONTEXT_REQUIRE(_mail->box->storage->user);
132 struct mail_namespace *ns = mailbox_get_namespace(_mail->box);
135 ret = mail_crypt_box_get_shared_key(_mail->box, pubkey_digest,
138 ret = mail_crypt_get_private_key(_mail->box, pubkey_digest,
152 mail_crypt_istream_opened(struct mail *_mail, struct istream **stream)
154 struct mail_private *mail = (struct mail_private *)_mail;
155 struct mail_user *user = _mail->box->storage->user;
161 if (_mail->uid > 0 && cache->uid == _mail->uid && cache->box == _mail->box) {
167 return mmail->super.istream_opened(_mail, stream);
173 return mmail->super.istream_opened(_mail, stream);
177 mail_crypt_istream_get_private_key, _mail);
180 *stream = mail_crypt_cache_open(muser, _mail, *stream);
181 return mmail->super.istream_opened(_mail, stream);
184 static void mail_crypt_close(struct mail *_mail)
186 struct mail_private *mail = (struct mail_private *)_mail;
189 MAIL_CRYPT_USER_CONTEXT_REQUIRE(_mail->box->storage->user);
193 if (_mail->uid > 0 && cache->uid == _mail->uid && cache->box == _mail->box) {
201 mmail->super.close(_mail);
204 static void mail_crypt_mail_allocated(struct mail *_mail)
207 MAIL_CRYPT_USER_CONTEXT(_mail->box->storage->user);
210 struct mail_private *mail = (struct mail_private *)_mail;