src/vfer_rcp.c File Reference

An rcp (remote copy) client, to be used with vfer_rcpd.c which implements the daemon. More...

#include "vfer_rcp.h"

Go to the source code of this file.

Data Structures

struct  rcp_info
 structure used for parsing the command line arguments and options of test_rcp More...

Functions

int main (int argc, char **argv)
int parse_opts (int argc, char **argv, FILE **testing_out)
void print_help (char *prog, int verbose)
int rcp_connect ()
void sig_handler (int sig)

Variables

vfer_fd connect_skt
int fd
rcp_info info
char * optarg
int opterr
int optind
int optopt
int sig_mark = 0


Detailed Description

An rcp (remote copy) client, to be used with vfer_rcpd.c which implements the daemon.

Author:
Ivan Beschastnikh
This program implements reliable transfer of data to and from the server running vfer_rcpd. It support scp style syntax.

Definition in file vfer_rcp.c.


Function Documentation

int main ( int  argc,
char **  argv 
)

main

Definition at line 342 of file vfer_rcp.c.

int parse_opts ( int  argc,
char **  argv,
FILE **  testing_out 
)

Parses the command line arguments and options to main()

This function will print descriptive errors it finds to stdout

Parameters:
argc is the argc argument to main
argv is the argv argument to main
testing_out is a FILE** type that is either set to NULL here or to 'stdout' depending on verbosity args
Returns:
1 on success [stop service] 0 on success [start service] -1 on error -2 if help option was specified

Definition at line 98 of file vfer_rcp.c.

void print_help ( char *  prog,
int  verbose 
)

Prints a verbose or a non-verbose usage page

Parameters:
prog program name to use in the help page
verbose controls whether the page is verbose(1) or not(0)

Definition at line 57 of file vfer_rcp.c.

int rcp_connect (  ) 

Sets up the connect_skt for sending and receiving files by doing all the socket api stuff

Definition at line 254 of file vfer_rcp.c.

void sig_handler ( int  sig  ) 

This function is a catcher of SIGINT signal, installed in main()

Definition at line 335 of file vfer_rcp.c.


Variable Documentation

vfer_fd connect_skt

Definition at line 46 of file vfer_rcp.c.

int fd

Definition at line 48 of file vfer_rcp.c.

rcp_info info

Definition at line 47 of file vfer_rcp.c.

char* optarg

int opterr

int optind

int optopt

int sig_mark = 0

Definition at line 49 of file vfer_rcp.c.


Generated on Tue Aug 8 16:07:22 2006 for VFER by  doxygen 1.4.7