fix missing initialization in tus_file_add()

this could lead to later assertion failures when the tus directory
contained failes not fit for loading (e.g. wrong size/magic etc)
because valid files would be munmap()ed.
parent a90304fd
......@@ -557,8 +557,8 @@ tus_file_unref(struct tus_file_core *fcore)
static void
tus_file_add(struct VPFX(tus_server) *srv, int basefd, const char *filename)
{
struct tus_file_core *fcore;
struct tus_file_disk *fdisk;
struct tus_file_core *fcore = NULL;
struct tus_file_disk *fdisk = NULL;
struct stat st;
int fd = -1;
const char *err;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment