From 3c80b42532bcd6924b6afb3cf6609b1d285906ac Mon Sep 17 00:00:00 2001 From: Aaron Jones Date: Thu, 15 Jan 2015 00:00:00 +0000 Subject: [PATCH] Allow clients to have a resolved hostname of localhost I slightly changed the patch to match surrounding style. (cherry picked from commit 0b06270fd6266c85d19e008efcd039605daf59d0) --- src/s_user.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/s_user.c b/src/s_user.c index 2d7705dc2..9ad3ee880 100644 --- a/src/s_user.c +++ b/src/s_user.c @@ -734,6 +734,9 @@ valid_hostname(const char *hostname) if(hostname == NULL) return NO; + if(!strcmp(hostname, "localhost")) + return YES; + if('.' == *p || ':' == *p || '/' == *p) return NO;