This repository has been archived on 2024-04-08. You can view files and clone it, but cannot push or open issues or pull requests.
deb-mbse/mbsebbs/transfer.h

44 lines
940 B
C
Raw Normal View History

2004-11-05 15:54:31 +00:00
#ifndef _TRANSFER_H
#define _TRANSFER_H
/* $Id$ */
/*
* List of files to download.
*/
typedef struct _down_list {
struct _down_list *next;
char *local; /* Local filename */
char *remote; /* Remove filename */
2005-10-11 20:49:41 +00:00
int cps; /* CPS after sent */
int area; /* File area or 0 */
unsigned int size; /* File size */
2004-11-05 15:54:31 +00:00
unsigned kfs : 1; /* Kill File Sent */
unsigned sent : 1; /* File is Sent */
2004-11-05 22:10:28 +00:00
unsigned failed : 1; /* Transfer failed */
2004-11-05 15:54:31 +00:00
} down_list;
2004-11-05 22:10:28 +00:00
2004-11-05 15:54:31 +00:00
/*
* List of uploaded files.
*/
typedef struct _up_list {
struct _up_list *next;
2004-11-06 22:01:51 +00:00
char *filename; /* Filename */
2005-10-11 20:49:41 +00:00
unsigned int size; /* Filesize */
2004-11-05 15:54:31 +00:00
} up_list;
2004-11-06 22:01:51 +00:00
int ForceProtocol(void);
2005-10-11 20:49:41 +00:00
void add_download(down_list **, char *, char *, int, unsigned int, int);
2004-11-06 22:01:51 +00:00
void tidy_download(down_list **);
int download(down_list *);
void tidy_upload(up_list **);
int upload(up_list **);
2005-10-11 20:49:41 +00:00
char *transfertime(struct timeval, struct timeval, int bytes, int);
2004-11-05 15:54:31 +00:00
#endif