File: dummy_hosts.pike

package info (click to toggle)
roxen 1.2beta2-3
  • links: PTS
  • area: contrib
  • in suites: slink
  • size: 16,920 kB
  • ctags: 8,589
  • sloc: ansic: 89,632; asm: 8,431; sh: 2,915; makefile: 1,784; cpp: 377
file content (20 lines) | stat: -rw-r--r-- 610 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
/* Dummy host_lookup, used when NO_DNS is defined. */

//string cvs_version = "$Id: dummy_hosts.pike,v 1.5 1998/02/10 18:36:03 per Exp $";
void create_host_name_lookup_processes() {}

string quick_host_to_ip(string h) { return h; }
string quick_ip_to_host(string h) { return h; }
string blocking_ip_to_host(string h) { return h; }
string blocking_host_to_ip(string h) { return h; }

void host_to_ip(string|void host, function|void callback, mixed ... args)
{
  return callback(0, @args);
}

void ip_to_host(string|void ipnumber, function|void callback, mixed ... args)
{
  return callback(ipnumber, @args);
}