From: Karel Zak <kzak@redhat.com>
To: Sami Kerola <kerolasa@iki.fi>
Cc: util-linux@vger.kernel.org
Subject: Re: [PATCH 12/23] libblkid: use pre-processor to optimize out code
Date: Wed, 1 Oct 2014 12:22:36 +0200 [thread overview]
Message-ID: <20141001102236.GL26272@x2.net.home> (raw)
In-Reply-To: <1411933916-30576-13-git-send-email-kerolasa@iki.fi>
On Sun, Sep 28, 2014 at 08:51:45PM +0100, Sami Kerola wrote:
> Signed-off-by: Sami Kerola <kerolasa@iki.fi>
> ---
> libblkid/src/superblocks/zfs.c | 6 ++++--
> 1 file changed, 4 insertions(+), 2 deletions(-)
>
> diff --git a/libblkid/src/superblocks/zfs.c b/libblkid/src/superblocks/zfs.c
> index 6ffa24d..088d110 100644
> --- a/libblkid/src/superblocks/zfs.c
> +++ b/libblkid/src/superblocks/zfs.c
> @@ -156,7 +156,6 @@ static void zfs_extract_guid_name(blkid_probe pr, loff_t offset)
> }
> }
>
> -#define zdebug(fmt, ...) do {} while(0)
> /*#define zdebug(fmt, a...) fprintf(stderr, fmt, ##a)*/
>
> /* ZFS has 128x1kB host-endian root blocks, stored in 2 areas at the start
> @@ -172,7 +171,9 @@ static int probe_zfs(blkid_probe pr,
> int tried;
> int found;
>
> +#ifdef zdebug
> zdebug("probe_zfs\n");
> +#endif
no, this is bad way. It's always better to use empty macros than
#ifdef, ifdef is evil
Karel
--
Karel Zak <kzak@redhat.com>
http://karelzak.blogspot.com
next prev parent reply other threads:[~2014-10-01 10:22 UTC|newest]
Thread overview: 30+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-09-28 19:51 [PATCH 00/23] pull: mostly textual and compiler warning fix changes Sami Kerola
2014-09-28 19:51 ` [PATCH 01/23] swapon: align available columns section in usage() Sami Kerola
2014-09-28 19:51 ` [PATCH 02/23] docs: update deprecation banners Sami Kerola
2014-09-28 19:51 ` [PATCH 03/23] hexdump: remove deprecation message Sami Kerola
2014-09-28 19:51 ` [PATCH 04/23] textual: fix couple typos in comments Sami Kerola
2014-09-28 19:51 ` [PATCH 05/23] flock: add error message to translations Sami Kerola
2014-09-28 19:51 ` [PATCH 06/23] textual: use version printing macro everywhere Sami Kerola
2014-09-28 19:51 ` [PATCH 07/23] textual: use manual tail usage() macro Sami Kerola
2014-09-28 19:51 ` [PATCH 08/23] textual: use usage() text element macros Sami Kerola
2014-09-28 19:51 ` [PATCH 09/23] libuuid: remove _SVID_SOURCE pre-processor definition Sami Kerola
2014-09-28 19:51 ` [PATCH 10/23] include: fix compiler warnings Sami Kerola
2014-09-28 19:51 ` [PATCH 11/23] lsblk: fix compiler warning Sami Kerola
2014-09-28 19:51 ` [PATCH 12/23] libblkid: use pre-processor to optimize out code Sami Kerola
2014-10-01 10:22 ` Karel Zak [this message]
2014-09-28 19:51 ` [PATCH 13/23] libblkid: fix implicit constant conversion warning Sami Kerola
2014-09-28 19:51 ` [PATCH 14/23] include/debug: remove duplicate 'const' declaration warning Sami Kerola
2014-09-28 19:51 ` [PATCH 15/23] cfdisk: add missing initializers to struct main_menuitems Sami Kerola
2014-10-01 10:27 ` Karel Zak
2014-09-28 19:51 ` [PATCH 16/23] findmnt: add missing initializers to struct colinfo Sami Kerola
2014-09-28 19:51 ` [PATCH 17/23] lsblk: " Sami Kerola
2014-09-28 19:51 ` [PATCH 18/23] hwclock: use fabs() instead abs() when argument is double Sami Kerola
2014-09-28 19:51 ` [PATCH 19/23] lscpu: add missing initializers to struct lscpu_coldesc Sami Kerola
2014-09-28 19:51 ` [PATCH 20/23] libsmartcols: add explicit column flags default Sami Kerola
2014-10-01 10:29 ` Karel Zak
2014-09-28 19:51 ` [PATCH 21/23] lslogins: add missing initializers to struct lslogins_coldesc Sami Kerola
2014-09-28 19:51 ` [PATCH 22/23] lslogins: use more narrow layout when initializing struct members Sami Kerola
2014-10-01 10:32 ` Karel Zak
2014-09-28 19:51 ` [PATCH 23/23] tests: fix the ipcs test for shmall being too big to show Sami Kerola
2014-10-01 9:45 ` Karel Zak
2014-10-01 11:14 ` [PATCH 00/23] pull: mostly textual and compiler warning fix changes Karel Zak
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=20141001102236.GL26272@x2.net.home \
--to=kzak@redhat.com \
--cc=kerolasa@iki.fi \
--cc=util-linux@vger.kernel.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;
as well as URLs for NNTP newsgroup(s).