All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ruediger Meier <sweet_f_a@gmx.de>
To: util-linux@vger.kernel.org
Subject: overriding STRTOXX_EXIT_CODE does not work
Date: Wed, 21 Jun 2017 18:56:05 +0200	[thread overview]
Message-ID: <201706211856.05354.sweet_f_a@gmx.de> (raw)

Hi,

I found a little annoying issue. The trick to re-define
STRTOXX_EXIT_CODE (see a99c913091c, 2012-03-30) can't work.
When compiling strutils.c it will always use the default from
strutils.h


STRTOXX_EXIT_CODE is used only at 3 places:

disk-utils/fsck.c:#define STRTOXX_EXIT_CODE     FSCK_EX_USAGE
misc-utils/blkid.c:#define STRTOXX_EXIT_CODE    BLKID_EXIT_OTHER
sys-utils/tunelp.c:#define STRTOXX_EXIT_CODE    3


But there are more candidates where the return codes are broken
since strutils.h was introduced, for example here f150ac37.

$ grep -l "strutils.h" `git grep -l   "FINDFS_\|MNT_EX\|MKFS_EX\|FSCK_EX" --  "*.c"`
disk-utils/fsck.c
disk-utils/fsck.cramfs.c
disk-utils/fsck.minix.c
disk-utils/mkfs.cramfs.c
disk-utils/mkfs.minix.c
libmount/src/context_mount.c
libmount/src/context_umount.c
sys-utils/fstrim.c
sys-utils/mount.c


Should we make STRTOXX_EXIT_CODE usable by moving  strutils.c to
strutils.h, like optutils.h? Or any other ideas?

cu,
Rudi

             reply	other threads:[~2017-06-21 16:56 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-06-21 16:56 Ruediger Meier [this message]
2017-06-21 22:06 ` overriding STRTOXX_EXIT_CODE does not work Karel Zak
2017-06-22  2:19   ` Ruediger Meier

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=201706211856.05354.sweet_f_a@gmx.de \
    --to=sweet_f_a@gmx.de \
    --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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.