Branch: Tag:

2017-06-16

2017-06-16 12:05:50 by Martin Nilsson <nilsson@fastmail.com>

Don't crash on empty requests.

1646:    protected mapping low_gethostbyname(string s, int type)    {    mapping m; -  if(sizeof(domains) && s[-1] != '.' && sizeof(s/".") < 3) { +  if(sizeof(domains) && sizeof(s) && s[-1] != '.' && sizeof(s/".") < 3) {    mapping m = do_sync_query(mkquery(s, C_IN, type));    if(!m || !m->an || !sizeof(m->an))    foreach(domains, string domain)