From fa7a74fcc8b3fdedb075cf2d04e70a20b326a632 Mon Sep 17 00:00:00 2001 From: Kent Overstreet Date: Thu, 26 May 2022 16:30:20 -0400 Subject: [PATCH] Delete some dead code printf_pad() has been superseded by printbuf tabstops. Signed-off-by: Kent Overstreet --- tools-util.c | 19 ------------------- tools-util.h | 2 -- 2 files changed, 21 deletions(-) diff --git a/tools-util.c b/tools-util.c index 591e2a0c..baf24ae5 100644 --- a/tools-util.c +++ b/tools-util.c @@ -126,25 +126,6 @@ struct stat xstat(const char *path) return statbuf; } -/* Formatting: */ - -int printf_pad(unsigned pad, const char * fmt, ...) -{ - va_list args; - int ret; - - va_start(args, fmt); - ret = vprintf(fmt, args); - va_end(args); - - while (ret++ < pad) - putchar(' '); - - return ret; -} - -/* Argument parsing stuff: */ - /* File parsing (i.e. sysfs) */ char *read_file_str(int dirfd, const char *path) diff --git a/tools-util.h b/tools-util.h index 136d7d65..8ed00b15 100644 --- a/tools-util.h +++ b/tools-util.h @@ -53,8 +53,6 @@ struct stat xstat(const char *); _ret; \ }) -int printf_pad(unsigned pad, const char * fmt, ...); - char *read_file_str(int, const char *); u64 read_file_u64(int, const char *);