From: Andy Whitcroft <apw@canonical.com>
To: Pavel Roskin <proski@gnu.org>
Cc: linux-kernel@vger.kernel.org
Subject: Re: checkpatch confused by pre-existing #endif
Date: Wed, 14 Jan 2009 16:45:39 +0000 [thread overview]
Message-ID: <20090114164539.GD10653@shadowen.org> (raw)
In-Reply-To: <1231883863.21706.17.camel@dv>
On Tue, Jan 13, 2009 at 04:57:43PM -0500, Pavel Roskin wrote:
> Hello!
>
> This patch confuses checkpatch.pl from Linux 2.6.29-rc1:
>
> ====================
> --- foo.h.old 2009-01-13 16:48:22.000000000 -0500
> +++ foo.h 2009-01-13 16:48:18.000000000 -0500
> @@ -3,4 +3,8 @@
>
>
>
> +#ifdef FOOBAR
> +#define foo
> +#endif
> +
> #endif /* FOO_H */
> ====================
>
> $ scripts/checkpatch.pl foo.diff
> Can't use an undefined value as an ARRAY reference at
> scripts/checkpatch.pl line 453.
>
> Apparently, the last #endif causes some data to be popped from the stack
> for preprocessor directives. However, the corresponding #ifdef is
> outside the patch, so this fails.
Yes this should be fixed in the changes pushed up to Andrew. You can
confirm this using the version here:
http://www.kernel.org/pub/linux/kernel/people/apw/checkpatch/checkpatch.pl-testing
-apw
next prev parent reply other threads:[~2009-01-14 16:46 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-01-13 21:57 checkpatch confused by pre-existing #endif Pavel Roskin
2009-01-14 16:45 ` Andy Whitcroft [this message]
2009-01-14 16:49 ` Pavel Roskin
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=20090114164539.GD10653@shadowen.org \
--to=apw@canonical.com \
--cc=linux-kernel@vger.kernel.org \
--cc=proski@gnu.org \
/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