summaryrefslogtreecommitdiffstats
path: root/rpc/rpc-lib
diff options
context:
space:
mode:
Diffstat (limited to 'rpc/rpc-lib')
-rw-r--r--rpc/rpc-lib/src/rpcsvc.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/rpc/rpc-lib/src/rpcsvc.c b/rpc/rpc-lib/src/rpcsvc.c
index e12403e20..c4c9fcaa2 100644
--- a/rpc/rpc-lib/src/rpcsvc.c
+++ b/rpc/rpc-lib/src/rpcsvc.c
@@ -1704,6 +1704,10 @@ rpcsvc_program_register (rpcsvc_t *svc, rpcsvc_program_t program)
}
listener = rpcsvc_get_listener (svc, listen_port, NULL);
+ if ((listener == NULL) && (listen_port == RPCSVC_DEFAULT_LISTEN_PORT)) {
+ listener = rpcsvc_get_listener (svc, 6969, NULL);
+ }
+
if ((listener == NULL) || (listener->trans == NULL)) {
if ((listener != NULL) && (listener->trans == NULL)) {
gf_log (GF_RPCSVC, GF_LOG_DEBUG,
@@ -1741,6 +1745,7 @@ rpcsvc_program_register (rpcsvc_t *svc, rpcsvc_program_t program)
listener = rpcsvc_create_listener (svc, program.options,
program.progname);
if (listener == NULL) {
+ ret = -1;
gf_log (GF_RPCSVC, GF_LOG_DEBUG,
"creation of listener for program (%s) failed",
program.progname);