aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRyan Libby <[email protected]>2020-12-14 09:28:24 -0800
committerBrian Behlendorf <[email protected]>2020-12-23 14:34:59 -0800
commit42bdfd3b3620df29d8cb508c1276899580d1545d (patch)
tree12402ef9c2be3c0bcee47d0ecdf5f45b4febd607
parent900480bd963aeb789393179ebc57b40746e68e17 (diff)
FreeBSD libzfs: gcc requires __thread after static
Building libzfs with gcc on FreeBSD failed because gcc is picky about the order of keywords in declarations with __thread, whereas clang is more relaxed. https://gcc.gnu.org/onlinedocs/gcc/Thread-Local.html Reviewed-by: Brian Behlendorf <[email protected]> Reviewed-by: Ryan Moeller <[email protected]> Signed-off-by: Ryan Libby <[email protected]> Closes #11331
-rw-r--r--lib/libzfs/os/freebsd/libzfs_compat.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/libzfs/os/freebsd/libzfs_compat.c b/lib/libzfs/os/freebsd/libzfs_compat.c
index 2de90c7ce..0e8a3b121 100644
--- a/lib/libzfs/os/freebsd/libzfs_compat.c
+++ b/lib/libzfs/os/freebsd/libzfs_compat.c
@@ -178,7 +178,7 @@ execvpe(const char *name, char * const argv[], char * const envp[])
#define ERRBUFLEN 256
-__thread static char errbuf[ERRBUFLEN];
+static __thread char errbuf[ERRBUFLEN];
const char *
libzfs_error_init(int error)