This repository has been archived on 2020-05-27. You can view files and clone it, but cannot push or open issues/pull-requests.
2009-02-18 03:33:36 -05:00
|
|
|
#ifndef __FILESYSTEM_H
|
|
|
|
#define __FILESYSTEM_H
|
|
|
|
|
|
|
|
/*
|
|
|
|
* This is the public API for CFTP's filesystem access. You just have to
|
|
|
|
* ask it to send or receive a file, and this will handle the rest. Errors
|
|
|
|
* raised if not accessible or if you are trying to overwrite a file. No files
|
|
|
|
* may be overwritten. All files written to client or server are saved in /tmp.
|
|
|
|
*
|
|
|
|
*/
|
|
|
|
|
|
|
|
/*
|
|
|
|
* The MAXFILE size is calculated to be the largest integer in CMDLEN - 1
|
2009-02-18 03:40:41 -05:00
|
|
|
* characters times MSGLEN. MAXFILE must be a multiple of MSGLEN.
|
2009-02-18 03:33:36 -05:00
|
|
|
*
|
2009-02-18 13:41:04 -05:00
|
|
|
* 9999 segments * 128 bytes = 1279872 bytes maximum for example
|
2009-02-18 03:33:36 -05:00
|
|
|
*
|
|
|
|
*/
|
|
|
|
#define MAXFILE 1279872
|
|
|
|
void send_file(int, const char *);
|
|
|
|
void receive_file(int, const char *);
|
|
|
|
|
|
|
|
#endif
|
|
|
|
|