commit - 35ed57e6c160dc13c2bbca2ca042406285d4ced3
commit + 44b7ff02fd34731c6ed0d552dbde5c9981d53127
blob - 92262b5d8b00c0ae3248c3010032ee8ff13ac0e1
blob + 2f8d771cc2ff81253cf62925757d7645ce39d539
--- src/ngircd/client.c
+++ src/ngircd/client.c
assert(Client != NULL);
+ /* Client isn't cloaked at all, return real hostname: */
if (!Client_HasMode(Client, 'x'))
return Client_Hostname(Client);
+ /* Client has received METADATA command, so it got the eventually
+ * cloaked hostname set correctly and this server doesn't need
+ * to cloak it on its own: */
+ if (strchr(Client_Flags(Client), 'M'))
+ return Client_Hostname(Client);
+
/* Do simple mapping to the server ID? */
if (!*Conf_CloakHostModeX)
return Client_ID(Client->introducer);