pipe-ident.h
musicmud-2.1.6/include/pipe-ident.h · 639 B
From the archive musicmud2.1.6.tar.gz
Download the archive « Back to the archive contents
#ifndef PIPE_IDENT_H
#define PIPE_IDENT_H
#include <string>
#include "Socket.h"
//! ident-lookup
namespace ident {
//! will be called with first arg = ticket returned from lookup, and second arg = the ident
typedef void (*handler_t)(int, const char *);
//! start the ident handler
void init();
//! poll the ident
void poll();
//! finish the ident handler
void done();
//! cause given pair of sockets to get idented
int lookup(InAddr *, InAddr *);
//! set the ident handler to call given function when it gets a response.
void set_handler(handler_t);
std::string dnslookup(InAddr *addr);
}
#endif