From 683f0b1d6c492987f639532809d357ba5767064d Mon Sep 17 00:00:00 2001 From: Brian Behlendorf Date: Mon, 22 Dec 2008 16:50:44 -0800 Subject: [PATCH 1/3] Fix cast --- cmd/ztest/ztest.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cmd/ztest/ztest.c b/cmd/ztest/ztest.c index 611b900533..b6c6c94bd0 100644 --- a/cmd/ztest/ztest.c +++ b/cmd/ztest/ztest.c @@ -764,11 +764,11 @@ ztest_replay_remove(ztest_replay_t *zr, lr_remove_t *lr, boolean_t byteswap) zil_replay_func_t *ztest_replay_vector[TX_MAX_TYPE] = { NULL, /* 0 no such transaction type */ - (zil_replay_func_t)ztest_replay_create, /* TX_CREATE */ + (zil_replay_func_t *)ztest_replay_create,/* TX_CREATE */ NULL, /* TX_MKDIR */ NULL, /* TX_MKXATTR */ NULL, /* TX_SYMLINK */ - (zil_replay_func_t)ztest_replay_remove, /* TX_REMOVE */ + (zil_replay_func_t *)ztest_replay_remove,/* TX_REMOVE */ NULL, /* TX_RMDIR */ NULL, /* TX_LINK */ NULL, /* TX_RENAME */ From 9ef0280a5c3d1a3d47971a739347432775bb3a88 Mon Sep 17 00:00:00 2001 From: Brian Behlendorf Date: Mon, 22 Dec 2008 16:51:28 -0800 Subject: [PATCH 2/3] Use pthread_ --- cmd/ztest/ztest.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmd/ztest/ztest.c b/cmd/ztest/ztest.c index 6fb9c60caf..a9873ab197 100644 --- a/cmd/ztest/ztest.c +++ b/cmd/ztest/ztest.c @@ -1132,7 +1132,7 @@ ztest_vdev_attach_detach(ztest_args_t *za) (longlong_t)newsize, replacing, error, expected_error); } - (void) mutex_unlock(&ztest_shared->zs_vdev_lock); + (void) pthread_mutex_unlock(&ztest_shared->zs_vdev_lock); } /* From 3a7614833888d6129a16f64785e49e7eb61eab37 Mon Sep 17 00:00:00 2001 From: Brian Behlendorf Date: Mon, 22 Dec 2008 16:52:26 -0800 Subject: [PATCH 3/3] Add a needed lib --- cmd/ztest/Makefile.am | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmd/ztest/Makefile.am b/cmd/ztest/Makefile.am index 9cbde71e0b..f4094347c6 100644 --- a/cmd/ztest/Makefile.am +++ b/cmd/ztest/Makefile.am @@ -25,4 +25,4 @@ ztest_LDADD = \ $(top_builddir)/lib/libzpool/libzpool.la \ $(top_builddir)/lib/libzfs/libzfs.la -ztest_LDFLAGS = -pthread -lm -lz -lrt +ztest_LDFLAGS = -pthread -lm -lz -lrt -ldl