1
0
Fork 0
mirror of git://git.psyced.org/git/psyced synced 2024-08-15 03:25:10 +00:00

let is_localhost() do its lower_case itself.. thx fip

This commit is contained in:
psyc://psyced.org/~lynX 2011-07-24 18:53:47 +02:00
parent 15dd8c0ada
commit a0cc248e00
15 changed files with 25 additions and 25 deletions

View file

@ -550,15 +550,15 @@ void dns_rresolve(string ip, closure callback, varargs array(mixed) extra) {
// {{{ function: is_localhost
#if 1
// take care to always pass a lowercased (virtual) hostname
int is_localhost(string host) {
// async discovery of virtual hosts is not necessary
// we should know all of our hostnames in advance for
// security anyway
return member(localhosts, host);
return member(localhosts, lower_case(host));
}
#else
int is_localhost(string host, closure callback, varargs array(mixed) extra) {
host = lower_case(host);
if (member(localhosts, host)) {
funcall(callback, 1, extra);
return;