From: Karel Zak Date: Wed, 5 Dec 2012 14:08:26 +0000 (+0100) Subject: fdisk: remove duplicate code (already in libfdisk) X-Git-Tag: v2.23-rc1~164 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=832f9ddf40bfc189fc8370a6fab78e1eb797d0ca;p=thirdparty%2Futil-linux.git fdisk: remove duplicate code (already in libfdisk) Signed-off-by: Karel Zak --- diff --git a/fdisks/utils.c b/fdisks/utils.c index db36290f50..275fee139a 100644 --- a/fdisks/utils.c +++ b/fdisks/utils.c @@ -442,33 +442,6 @@ int fdisk_create_disklabel(struct fdisk_context *cxt, const char *name) return cxt->label->create(cxt); } -/** - * fdisk_init_debug: - * @mask: debug mask (0xffff to enable full debuging) - * - * If the @mask is not specified then this function reads - * FDISK_DEBUG environment variable to get the mask. - * - * Already initialized debugging stuff cannot be changed. It does not - * have effect to call this function twice. - */ -void fdisk_init_debug(int mask) -{ - if (fdisk_debug_mask & FDISK_DEBUG_INIT) - return; - if (!mask) { - char *str = getenv("FDISK_DEBUG"); - if (str) - fdisk_debug_mask = strtoul(str, 0, 0); - } else - fdisk_debug_mask = mask; - - if (fdisk_debug_mask) - fprintf(stderr, "fdisk: debug mask set to 0x%04x.\n", - fdisk_debug_mask); - fdisk_debug_mask |= FDISK_DEBUG_INIT; -} - /** * fdisk_new_context: * @fname: path to the device to be handled