refactor: split monolithic modules and extract shared components

- Remove dead socket.c/socket.h (accumulated duplicate symbols)
- Extract compression.h/c (data_compress/decompress from data.c)
- Extract io.h/c (low-level I/O from protocol.c)
- Extract metadata.h/c (unified metadata wire format from file.c, chunk.c, utils.c)
- Split client.c into client_cli.c (CLI parsing) + client_send.c (send logic)
- Move receiver pipeline threads from server.c to multiprocessing.c
- Move to_disk/file_restore_metadata from utils.c to file.c/metadata.c
- Fix const qualifiers on to_disk and str_dup signatures
- Suppress chown unused-result warning
This commit is contained in:
2026-07-15 19:36:26 +02:00
parent b3f69208ce
commit 02619cca5c
29 changed files with 942 additions and 832 deletions
+15
View File
@@ -0,0 +1,15 @@
#ifndef CLIENT_SEND_H
#define CLIENT_SEND_H
#include "chunk.h"
#include "config.h"
#include "transport_tcp.h"
extern char *server_host;
extern int server_port;
int send_chunk(Client *client, Chunk *chunk, Config *config);
int send_files(Config *config);
int send_files_multithreaded(Config *config);
#endif