fix the compilation warning

This commit is contained in:
z3APA3A 2020-12-02 11:13:55 +03:00
parent 252c4cb36b
commit 29f8867a9e

View File

@ -293,7 +293,7 @@ int parsehostname(char *hostname, struct clientparam *param, unsigned short port
if(!hostname || !*hostname)return 2;
if(*hostname == '[') se=strchr(hostname, ']');
if (sp = strchr(se?se:hostname, ':')) {
if ((sp = strchr(se?se:hostname, ':'))) {
if(strchr(sp+1, ':'))sp = NULL;
else *sp = 0;
}