aboutsummaryrefslogtreecommitdiffstats
path: root/com32/sysdump/backend.h
diff options
context:
space:
mode:
Diffstat (limited to 'com32/sysdump/backend.h')
-rw-r--r--com32/sysdump/backend.h30
1 files changed, 7 insertions, 23 deletions
diff --git a/com32/sysdump/backend.h b/com32/sysdump/backend.h
index 0be80c63..21a9ff83 100644
--- a/com32/sysdump/backend.h
+++ b/com32/sysdump/backend.h
@@ -15,41 +15,26 @@ struct backend {
const char *helpmsg;
int minargs;
- unsigned int blocksize;
- unsigned int flags;
-
size_t dbytes;
size_t zbytes;
+ const char **argv;
- int (*open)(struct backend *, const char *argv[], size_t len);
- int (*write)(struct backend *, const char *buf, size_t len);
+ int (*write)(struct backend *);
z_stream zstream;
char *outbuf;
-
- union {
- struct {
- uint32_t my_ip;
- uint32_t srv_ip;
- uint16_t my_port;
- uint16_t srv_port;
- uint16_t seq;
- } tftp;
- struct {
- struct serial_if serial;
- uint16_t seq;
- } ymodem;
- };
+ size_t alloc;
};
/* zout.c */
-int init_data(struct backend *be, const char *argv[], size_t len);
-int write_data(struct backend *be, const void *buf, size_t len, bool flush);
+int init_data(struct backend *be, const char *argv[]);
+int write_data(struct backend *be, const void *buf, size_t len);
+int flush_data(struct backend *be);
/* cpio.c */
int cpio_hdr(struct backend *be, uint32_t mode, size_t datalen,
const char *filename);
-int cpio_init(struct backend *be, const char *argv[], size_t len);
+int cpio_init(struct backend *be, const char *argv[]);
int cpio_mkdir(struct backend *be, const char *filename);
int cpio_writefile(struct backend *be, const char *filename,
const void *data, size_t len);
@@ -63,6 +48,5 @@ struct backend *get_backend(const char *name);
/* backends */
extern struct backend be_tftp;
extern struct backend be_ymodem;
-extern struct backend be_null;
#endif /* BACKEND_H */