unofficial mirror of notmuch@notmuchmail.org
 help / color / mirror / code / Atom feed
From: rhn <nomumali.rhn@porcupinefactory.org>
To: Tomi Ollila <tomi.ollila@iki.fi>
Cc: rhn <gihu.rhn@porcupinefactory.org>, notmuch@notmuchmail.org
Subject: Re: [PATCH 0/3] API: add notes on lifetimes
Date: Sun, 23 Dec 2018 11:08:29 +0100	[thread overview]
Message-ID: <20181223110829.2e68feab.rhn@porcupinefactory.org> (raw)
In-Reply-To: <m2k1k7rk9y.fsf@guru.guru-group.fi>

On Mon, 17 Dec 2018 22:05:45 +0200
Tomi Ollila <tomi.ollila@iki.fi> wrote:

> On Mon, Dec 17 2018, rhn wrote:
> 
> > Hi,
> >
> > this patch series addresses API shortcomings that were found while working on the Rust bindings [0].
> >
> > The first two patches address the problem that the docs never clearly state when messages obtained as replies are destroyed, while the last patch fixes abroken API example.
> >
> > Thanks for Dirk Van Haerenborgh for working out how long notmuch objects live.  
> 
> Looks good. Have to trust that change in example is correct (why would it
> not be?) I hope tests pass :D
> 
> Tomi

The tests obviously pass, you can check them yourself. They are unfortunately prone to false negatives (e.g. passes when it shouldn't), because freed memory can still be sometimes accessed.

They could be detected more reliably if valgrind's memcheck was part of the test suite, but I think this patch still adds value.

I'm eagerly hoping for a merge!

Cheers,
rhn

> 
> >
> > Cheers,
> > rhn
> >
> > [0] https://github.com/vhdirk/notmuch-rs
> >
> > rhn (3):
> >   lib: Explicitly state when replies will be destroyed
> >   test: Check for replies obeying lifetime guarantees
> >   docs: Use correct call to notmuch_query_search_threads in usage
> >     example
> >
> >  lib/notmuch.h             | 10 ++++-
> >  test/T720-lib-lifetime.sh | 83 +++++++++++++++++++++++++++++++++++++++
> >  2 files changed, 92 insertions(+), 1 deletion(-)
> >  create mode 100755 test/T720-lib-lifetime.sh
> >
> > -- 
> > 2.17.2
> >
> > _______________________________________________
> > notmuch mailing list
> > notmuch@notmuchmail.org
> > https://notmuchmail.org/mailman/listinfo/notmuch  

      reply	other threads:[~2018-12-23 10:17 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-12-17 17:57 [PATCH 0/3] API: add notes on lifetimes rhn
2018-12-17 17:57 ` [PATCH 1/3] lib: Explicitly state when replies will be destroyed rhn
2018-12-17 17:57 ` [PATCH 2/3] test: Check for replies obeying lifetime guarantees rhn
2018-12-17 17:57 ` [PATCH 3/3] docs: Use correct call to notmuch_query_search_threads in usage example rhn
2019-01-26  1:14   ` David Bremner
2018-12-17 20:05 ` [PATCH 0/3] API: add notes on lifetimes Tomi Ollila
2018-12-23 10:08   ` rhn [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://notmuchmail.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20181223110829.2e68feab.rhn@porcupinefactory.org \
    --to=nomumali.rhn@porcupinefactory.org \
    --cc=gihu.rhn@porcupinefactory.org \
    --cc=notmuch@notmuchmail.org \
    --cc=tomi.ollila@iki.fi \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://yhetil.org/notmuch.git/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).