diff --git a/cmd/ztest/ztest.c b/cmd/ztest/ztest.c index 5d946294b..484637997 100644 --- a/cmd/ztest/ztest.c +++ b/cmd/ztest/ztest.c @@ -132,7 +132,7 @@ #include #include #include -#ifdef __GLIBC__ +#if (__GLIBC__ && !__UCLIBC__) #include /* for backtrace() */ #endif @@ -556,7 +556,7 @@ dump_debug_buffer(void) static void sig_handler(int signo) { struct sigaction action; -#ifdef __GLIBC__ /* backtrace() is a GNU extension */ +#if (__GLIBC__ && !__UCLIBC__) /* backtrace() is a GNU extension */ int nptrs; void *buffer[BACKTRACE_SZ]; diff --git a/tests/zfs-tests/cmd/xattrtest/xattrtest.c b/tests/zfs-tests/cmd/xattrtest/xattrtest.c index 42c510ed0..8c4cb8895 100644 --- a/tests/zfs-tests/cmd/xattrtest/xattrtest.c +++ b/tests/zfs-tests/cmd/xattrtest/xattrtest.c @@ -44,11 +44,9 @@ #include #include -extern char *program_invocation_short_name; - #define ERROR(fmt, ...) \ - fprintf(stderr, "%s: %s:%d: %s: " fmt "\n", \ - program_invocation_short_name, __FILE__, __LINE__, \ + fprintf(stderr, "xattrtest: %s:%d: %s: " fmt "\n", \ + __FILE__, __LINE__, \ __func__, ## __VA_ARGS__); static const char shortopts[] = "hvycdn:f:x:s:p:t:e:rRko:";