rget.c File Reference

#include <sys/types.h>
#include <sys/ioctl.h>
#include <stdio.h>
#include <fcntl.h>
#include <stdlib.h>
#include <unistd.h>
#include <string.h>
#include <errno.h>
#include <sys/socket.h>
#include <netinet/in.h>
#include <netdb.h>

Include dependency graph for rget.c:

Go to the source code of this file.

Defines

#define nil   ((void*)0)

Functions

static void fatal (const char *label)
static unsigned name2port (char *n)
static void usage (void)
int main (int argc, char **argv)

Variables

static char * name
static int iflag
static int oflag
static int hflag
static int lflag
static int cflag
static char * host
static struct hostenthent
static char * key
static char ** cmdv


Define Documentation

#define nil   ((void*)0)
 

Definition at line 9 of file rget.c.


Function Documentation

static void fatal const char *  label  )  [static]
 

Definition at line 41 of file rget.c.

References err, errno, exit(), fprintf(), stderr, and strerror().

int main int  argc,
char **  argv
 

Definition at line 77 of file rget.c.

References accept, AF_INET, bind, cflag, close, cmdv, connect, exit(), fatal(), fprintf(), getenv(), gethostbyname, hent, hflag, host, htonl, i, iflag, INADDR_ANY, ioctl, IPPROTO_TCP, key, lflag, listen, memcpy(), memset(), n, name2port(), nil, NWIOSTCPCONF, NWIOTCPCONN, NWIOTCPLISTEN, NWTC_EXCL, nwio_tcpconf::nwtc_flags, nwio_tcpconf::nwtc_locport, NWTC_LP_SEL, NWTC_LP_SET, nwio_tcpconf::nwtc_remaddr, nwio_tcpconf::nwtc_remport, NWTC_SET_RA, NWTC_SET_RP, NWTC_UNSET_RA, NWTC_UNSET_RP, nwio_tcpcl::nwtcl_flags, O_RDWR, oflag, open, s, setsockopt, sleep, SO_REUSEADDR, SOCK_STREAM, socket, SOL_SOCKET, stderr, strcmp, strrchr(), tcp_device, and usage.

static unsigned name2port char *  n  )  [static]
 

Definition at line 49 of file rget.c.

References htons, and strtoul().

Referenced by main().

static void usage void   )  [static]
 

Definition at line 63 of file rget.c.

References exit(), fprintf(), and stderr.


Variable Documentation

int cflag [static]
 

Definition at line 35 of file rget.c.

char** cmdv [static]
 

Definition at line 39 of file rget.c.

Referenced by main().

struct hostent* hent [static]
 

Definition at line 37 of file rget.c.

Referenced by main().

int hflag [static]
 

Definition at line 35 of file rget.c.

char* host [static]
 

Definition at line 36 of file rget.c.

int iflag [static]
 

Definition at line 35 of file rget.c.

char* key [static]
 

Definition at line 38 of file rget.c.

int lflag [static]
 

Definition at line 35 of file rget.c.

char* name [static]
 

Definition at line 34 of file rget.c.

int oflag [static]
 

Definition at line 35 of file rget.c.


Generated on Fri Apr 14 23:07:21 2006 for minix by  doxygen 1.4.6