Linux Test Project
 help / color / mirror / Atom feed
From: Cyril Hrubis <chrubis@suse.cz>
To: Petr Vorel <pvorel@suse.cz>
Cc: Vlad Yasevich <vyasevich@gmail.com>,
	Marcelo Ricardo Leitner <marcelo.leitner@gmail.com>,
	Neil Horman <nhorman@tuxdriver.com>,
	ltp@lists.linux.it, linux-sctp@vger.kernel.org
Subject: Re: [LTP] [PATCH 1/2] sctputil.h: Fix some formatting
Date: Thu, 17 Feb 2022 10:42:41 +0100	[thread overview]
Message-ID: <Yg4YkbUB3moje7Y8@yuki> (raw)
In-Reply-To: <20220203170522.22051-2-pvorel@suse.cz>

Hi!
>  static inline void *test_malloc(size_t size)
>  {
>  	void *buf = malloc(size);
> -        if (NULL == buf)
> -                tst_brkm(TBROK, tst_exit, "malloc failed");
> +
> +	if (NULL == buf)
> +		tst_brkm(TBROK, tst_exit, "malloc failed");

This one has still constant on the right and I would rather change this
to the more common if (!buf) variant as well.

Other than that it's pretty obviously fine:

Reviewed-by: Cyril Hrubis <chrubis@suse.cz>

>  	return buf;
>  }
>  
> -- 
> 2.35.1
> 

-- 
Cyril Hrubis
chrubis@suse.cz

-- 
Mailing list info: https://lists.linux.it/listinfo/ltp

  reply	other threads:[~2022-02-17  9:40 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-02-03 17:05 [LTP] [PATCH 0/2] Fix SCTP tests on systems with disabled IPv6 Petr Vorel
2022-02-03 17:05 ` [LTP] [PATCH 1/2] sctputil.h: Fix some formatting Petr Vorel
2022-02-17  9:42   ` Cyril Hrubis [this message]
2022-02-17  9:45   ` Cyril Hrubis
2022-02-03 17:05 ` [LTP] [PATCH 2/2] sctputil.h: TCONF on EAFNOSUPPORT Petr Vorel
2022-02-17  9:56   ` Cyril Hrubis
2022-02-17 11:45     ` Petr Vorel
2022-02-17 12:18     ` Petr Vorel

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=Yg4YkbUB3moje7Y8@yuki \
    --to=chrubis@suse.cz \
    --cc=linux-sctp@vger.kernel.org \
    --cc=ltp@lists.linux.it \
    --cc=marcelo.leitner@gmail.com \
    --cc=nhorman@tuxdriver.com \
    --cc=pvorel@suse.cz \
    --cc=vyasevich@gmail.com \
    /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