From 550579e062adf730cde8d4a4b4abe36a3605e101 Mon Sep 17 00:00:00 2001 From: Michael Tremer Date: Wed, 5 Feb 2025 10:18:11 +0000 Subject: [PATCH] pakfire: Initialize the directory file descriptor Signed-off-by: Michael Tremer --- src/pakfire/pakfire.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/pakfire/pakfire.c b/src/pakfire/pakfire.c index 7ef5f3ed..c58f9241 100644 --- a/src/pakfire/pakfire.c +++ b/src/pakfire/pakfire.c @@ -1026,6 +1026,9 @@ int pakfire_create(struct pakfire** pakfire, struct pakfire_ctx* ctx, // Store a reference to the configuration p->config = pakfire_config_ref(config); + // Initialize file descriptors + p->fd = -EBADF; + // Store the nominal architecture r = pakfire_string_set(p->arches.nominal, arch); if (r < 0) -- 2.47.3