Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1490634
| From | Stefan Richter <stefanr@s5r6.in-berlin.de> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH 10/10] firewire-net: Adjust checks for null pointers in five functions |
| Date | 2016-09-24 14:10 +0200 |
| Message-ID | <skTWh-P9-17@gated-at.bofh.it> (permalink) |
| References | <qEuGl-43C-5@gated-at.bofh.it> <siDsB-4oB-3@gated-at.bofh.it> <siDLX-4vi-7@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On Sep 18 SF Markus Elfring wrote: > The script "checkpatch.pl" can point information out like the following. A side note: checkpatch.pl is for authors to help prepare their submissions of new code (or their refactoring of existing code if for some reason a refactoring is undertaken). > Comparison to NULL could be written !… Yes it could, or it could remain as is. Both styles are used in drivers/firewire/net.c, so it is indeed preferable to normalize it to one of them. I keep your patch for the next occasion when related work is being done on drivers/firewire/net.c or drivers/firewire. > Thus fix the affected source code places. It is not a "fix", it is a stylistic change. > Signed-off-by: Markus Elfring <elfring@users.sourceforge.net> > --- > drivers/firewire/net.c | 16 ++++++++-------- > 1 file changed, 8 insertions(+), 8 deletions(-) > > diff --git a/drivers/firewire/net.c b/drivers/firewire/net.c > index eb7ce5e..e313be3 100644 > --- a/drivers/firewire/net.c > +++ b/drivers/firewire/net.c > @@ -366,13 +366,13 @@ static struct fwnet_partial_datagram *fwnet_pd_new(struct net_device *net, > > INIT_LIST_HEAD(&new->fi_list); > fi = fwnet_frag_new(new, frag_off, frag_len); > - if (fi == NULL) > + if (!fi) > goto free_new; [...] -- Stefan Richter -======----- =--= ==--- http://arcgraph.de/sr/
Back to linux.kernel | Previous | Next | Find similar | Unroll thread
Re: [PATCH 10/10] firewire-net: Adjust checks for null pointers in five functions Stefan Richter <stefanr@s5r6.in-berlin.de> - 2016-09-24 14:10 +0200
csiph-web