From 8724c83390faff7cb576c567540715b1f315bd37 Mon Sep 17 00:00:00 2001 From: Ronnie Sahlberg Date: Wed, 11 Jan 2012 07:04:01 +1100 Subject: [PATCH] Add function to get root filehandle from a nfs context --- include/libnfs-private.h | 1 + lib/libnfs.c | 3 +++ 2 files changed, 4 insertions(+) diff --git a/include/libnfs-private.h b/include/libnfs-private.h index b1fe134..29f0406 100644 --- a/include/libnfs-private.h +++ b/include/libnfs-private.h @@ -104,3 +104,4 @@ void rpc_unset_autoreconnect(struct rpc_context *rpc); int rpc_add_fragment(struct rpc_context *rpc, char *data, uint64_t size); void rpc_free_all_fragments(struct rpc_context *rpc); +const struct nfs_fh3 *nfs_get_rootfh(struct nfs_context *nfs); diff --git a/lib/libnfs.c b/lib/libnfs.c index ace4466..8c7ad4e 100644 --- a/lib/libnfs.c +++ b/lib/libnfs.c @@ -3512,3 +3512,6 @@ const char *nfs_get_export(struct nfs_context *nfs) { return nfs->export; } +const struct nfs_fh3 *nfs_get_rootfh(struct nfs_context *nfs) { + return &nfs->rootfh; +} -- 2.34.1