public inbox for cocci@systeme.lip6.fr
 help / color / mirror / Atom feed
From: tipecaml@gmail.com (Cyril Roelandt)
To: cocci@systeme.lip6.fr
Subject: [Cocci] [Review needed] Ensure that calls to d_find_alias() are followed by dput().
Date: Thu, 08 Nov 2012 21:09:49 +0100	[thread overview]
Message-ID: <509C118D.3010109@gmail.com> (raw)
In-Reply-To: <alpine.DEB.2.02.1211080820540.1945@localhost6.localdomain6>

On 11/08/2012 08:21 AM, Julia Lawall wrote:
> How many cases do you find?
>

Well, only 2 cases (in drivers/iommu/tegra-smmu.c and fs/ceph/export.c). 
It's worth noticing that the d_find_alias() function is only called 20 
times though, so this seems to be quite a common mistake.

I attached an updated semantic patch, to deal with cases where the 
dentry is assigned a new value and dput() has not been called.


WBR,
Cyril Roelandt.
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: d_find_alias.cocci
URL: <https://systeme.lip6.fr/pipermail/cocci/attachments/20121108/750882da/attachment.ksh>

  reply	other threads:[~2012-11-08 20:09 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-11-08  1:31 [Cocci] [Review needed] Ensure that calls to d_find_alias() are followed by dput() Cyril Roelandt
2012-11-08  7:21 ` Julia Lawall
2012-11-08 20:09   ` Cyril Roelandt [this message]
2012-11-09 11:12     ` Peter Senna Tschudin
2012-11-09 21:29     ` Julia Lawall
2012-11-21 23:51       ` Cyril Roelandt
  -- strict thread matches above, loose matches on Subject: below --
2012-11-08  1:29 Cyril Roelandt

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

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

  git send-email \
    --in-reply-to=509C118D.3010109@gmail.com \
    --to=tipecaml@gmail.com \
    --cc=cocci@systeme.lip6.fr \
    /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.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox