Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1715288
| From | Jeff Layton <jlayton@redhat.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH 2/2] lockd: Adjust 61 checks for null pointers |
| Date | 2017-08-18 18:10 +0200 |
| Message-ID | <ufS0q-63B-17@gated-at.bofh.it> (permalink) |
| References | <ufu7L-67i-3@gated-at.bofh.it> <ufu7L-67i-15@gated-at.bofh.it> <ufRQK-5Ky-5@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On Fri, 2017-08-18 at 15:53 +0000, Trond Myklebust wrote: > On Thu, 2017-08-17 at 16:34 +0200, SF Markus Elfring wrote: > > From: Markus Elfring <elfring@users.sourceforge.net> > > Date: Thu, 17 Aug 2017 16:00:18 +0200 > > MIME-Version: 1.0 > > Content-Type: text/plain; charset=UTF-8 > > Content-Transfer-Encoding: 8bit > > > > The script “checkpatch.pl” pointed information out like the > > following. > > > > Comparison to NULL could be written … > > > > Thus fix the affected source code places. > > > > Signed-off-by: Markus Elfring <elfring@users.sourceforge.net> > > --- > > fs/lockd/clnt4xdr.c | 12 ++++++------ > > fs/lockd/clntlock.c | 10 +++++----- > > fs/lockd/clntproc.c | 12 ++++++------ > > fs/lockd/clntxdr.c | 12 ++++++------ > > fs/lockd/host.c | 22 +++++++++++----------- > > fs/lockd/mon.c | 16 ++++++++-------- > > fs/lockd/svc.c | 4 ++-- > > fs/lockd/svc4proc.c | 6 +++--- > > fs/lockd/svclock.c | 14 +++++++------- > > fs/lockd/svcproc.c | 6 +++--- > > fs/lockd/svcshare.c | 2 +- > > fs/lockd/svcsubs.c | 3 +-- > > 12 files changed, 59 insertions(+), 60 deletions(-) > > > > diff --git a/fs/lockd/clnt4xdr.c b/fs/lockd/clnt4xdr.c > > index c349fc0f9b80..ec6473d194fd 100644 > > --- a/fs/lockd/clnt4xdr.c > > +++ b/fs/lockd/clnt4xdr.c > > @@ -131,7 +131,7 @@ static int decode_netobj(struct xdr_stream *xdr, > > __be32 *p; > > > > p = xdr_inline_decode(xdr, 4); > > - if (unlikely(p == NULL)) > > + if (unlikely(!p)) > > Oh STOP with the checkpatch wankfest! > :) To elaborate: these kinds of patches are particularly unwelcome. In particular, these sorts of changes make it difficult to backport later patches to earlier kernels. If you're doing meaningful work in these areas of code, then feel free to change the style at the same time. If not though, it's best to leave them alone. Cheers, -- Jeff Layton <jlayton@redhat.com>
Back to linux.kernel | Previous | Next — Previous in thread | Find similar | Unroll thread
[PATCH 2/2] lockd: Adjust 61 checks for null pointers SF Markus Elfring <elfring@users.sourceforge.net> - 2017-08-17 16:40 +0200
Re: [PATCH 2/2] lockd: Adjust 61 checks for null pointers Trond Myklebust <trondmy@primarydata.com> - 2017-08-18 18:00 +0200
Re: [PATCH 2/2] lockd: Adjust 61 checks for null pointers Jeff Layton <jlayton@redhat.com> - 2017-08-18 18:10 +0200
csiph-web