summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--libglusterfs/src/common-utils.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libglusterfs/src/common-utils.c b/libglusterfs/src/common-utils.c
index c9c396762..280cf2189 100644
--- a/libglusterfs/src/common-utils.c
+++ b/libglusterfs/src/common-utils.c
@@ -1644,7 +1644,7 @@ valid_host_name (char *address, int length)
char *temp_str = NULL;
char *save_ptr = NULL;
- if ((length > _POSIX_HOST_NAME_MAX) || (length == 1)) {
+ if ((length > _POSIX_HOST_NAME_MAX) || (length < 1)) {
ret = 0;
goto out;
}