journal-remote: fix two minor memory leaks

This commit is contained in:
Antonio Alvarez Feijoo 2024-04-11 17:20:02 +02:00 committed by Mike Yuan
parent fc49bf6041
commit 3ec49af973
2 changed files with 3 additions and 0 deletions

View file

@ -50,6 +50,7 @@ static char **arg_file = NULL;
STATIC_DESTRUCTOR_REGISTER(arg_key_pem, erase_and_freep);
STATIC_DESTRUCTOR_REGISTER(arg_cert_pem, freep);
STATIC_DESTRUCTOR_REGISTER(arg_trust_pem, freep);
STATIC_DESTRUCTOR_REGISTER(arg_file, strv_freep);
typedef struct RequestMeta {
sd_journal *journal;

View file

@ -59,6 +59,8 @@ static int arg_follow = -1;
static const char *arg_save_state = NULL;
static usec_t arg_network_timeout_usec = USEC_INFINITY;
STATIC_DESTRUCTOR_REGISTER(arg_file, strv_freep);
static void close_fd_input(Uploader *u);
#define SERVER_ANSWER_KEEP 2048