summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChuck Lever <chuck.lever@oracle.com>2009-01-07 12:33:09 -0500
committerSteve Dickson <steved@redhat.com>2009-01-07 12:33:09 -0500
commit29ac873f9024c8fcbca38ab09ba54cda3765b746 (patch)
treeed29a5821e6050655dbbc4b81da37c7f6822f5d9
parentba05418f589c2d01f4e7e44c70d4844f43511927 (diff)
downloadnfs-utils-29ac873f9024c8fcbca38ab09ba54cda3765b746.tar.gz
nfs-utils-29ac873f9024c8fcbca38ab09ba54cda3765b746.tar.xz
nfs-utils-29ac873f9024c8fcbca38ab09ba54cda3765b746.zip
showmount command: Quiesce warning when TI-RPC is disabled
Make sure nfs_sm_pgmtbl is not compiled if TI-RPC functions are not available. This quiesces the following compiler warning: showmount.c:53: warning: nfs_sm_pgmtbl defined but not used Signed-off-by: Chuck Lever <chuck.lever@oracle.com> Signed-off-by: Steve Dickson <steved@redhat.com>
-rw-r--r--utils/showmount/showmount.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/utils/showmount/showmount.c b/utils/showmount/showmount.c
index 17f7d87..2695c51 100644
--- a/utils/showmount/showmount.c
+++ b/utils/showmount/showmount.c
@@ -50,13 +50,6 @@ static int aflag = 0;
static int dflag = 0;
static int eflag = 0;
-static const char *nfs_sm_pgmtbl[] = {
- "showmount",
- "mount",
- "mountd",
- NULL,
-};
-
static struct option longopts[] =
{
{ "all", 0, 0, 'a' },
@@ -87,6 +80,13 @@ static void usage(FILE *fp, int n)
#ifdef HAVE_CLNT_CREATE
+static const char *nfs_sm_pgmtbl[] = {
+ "showmount",
+ "mount",
+ "mountd",
+ NULL,
+};
+
/*
* Generate an RPC client handle connected to the mountd service
* at @hostname, or die trying.