diff options
author | Raghavendra Bhat <raghavendra@redhat.com> | 2013-02-26 18:34:53 +0530 |
---|---|---|
committer | Anand Avati <avati@redhat.com> | 2013-02-28 15:22:45 -0800 |
commit | 29e75759d574952db96d9a85e20804af1eec7327 (patch) | |
tree | 2054e175a3a4d25c85a8cca9a9455c166fdd9691 /libglusterfs | |
parent | d4269b00008ea727a0312a55f543f18e9a0d5edd (diff) |
libglusterfs: avoid the logging which says the port is invalid
If the reserved ports file in proc contains just a newline, then
do not proceed with ports checking and reserving.
Change-Id: If610b0e49a97e5c22e7e2b1bb4155c9616a4612a
BUG: 762989
Signed-off-by: Raghavendra Bhat <raghavendra@redhat.com>
Reviewed-on: http://review.gluster.org/4583
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Jeff Darcy <jdarcy@redhat.com>
Diffstat (limited to 'libglusterfs')
-rw-r--r-- | libglusterfs/src/common-utils.c | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/libglusterfs/src/common-utils.c b/libglusterfs/src/common-utils.c index 95b8abf6969..c49e6d1f564 100644 --- a/libglusterfs/src/common-utils.c +++ b/libglusterfs/src/common-utils.c @@ -2291,17 +2291,11 @@ gf_process_reserved_ports (gf_boolean_t *ports) goto out; } - blocked_port = strtok_r (ports_info, ",",&tmp); - if (!blocked_port || !strcmp (blocked_port, ports_info)) { - if (!blocked_port) - blocked_port = ports_info; - gf_ports_reserved (blocked_port, ports); - blocked_port = strtok_r (NULL, ",", &tmp); - } + blocked_port = strtok_r (ports_info, ",\n",&tmp); while (blocked_port) { gf_ports_reserved (blocked_port, ports); - blocked_port = strtok_r (NULL, ",", &tmp); + blocked_port = strtok_r (NULL, ",\n", &tmp); } ret = 0; |