]> git.ipfire.org Git - pakfire.git/commitdiff
repos: Drop flags argument from compose function
authorMichael Tremer <michael.tremer@ipfire.org>
Thu, 1 Jun 2023 15:44:37 +0000 (15:44 +0000)
committerMichael Tremer <michael.tremer@ipfire.org>
Thu, 1 Jun 2023 15:44:37 +0000 (15:44 +0000)
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
src/_pakfire/pakfire.c
src/libpakfire/include/pakfire/repo.h
src/libpakfire/repo.c
tests/libpakfire/repo.c

index 764e3eb1f1e8bddad76dc9bc89b87791badda463..f41ccaec2483450fec16dc052a5a930fbdbe0ecd 100644 (file)
@@ -1418,8 +1418,6 @@ static PyObject* Pakfire_repo_compose(PakfireObject* self, PyObject* args, PyObj
                return NULL;
        }
 
-       const int flags = 0;
-
        // How many new files do we have?
        ssize_t num_files = PySequence_Length(list);
        if (num_files < 0)
@@ -1453,7 +1451,7 @@ static PyObject* Pakfire_repo_compose(PakfireObject* self, PyObject* args, PyObj
 
        Py_BEGIN_ALLOW_THREADS
 
-       int r = pakfire_repo_compose(self->pakfire, path, flags, files);
+       int r = pakfire_repo_compose(self->pakfire, path, files);
        if (r) {
                Py_BLOCK_THREADS
                PyErr_SetFromErrno(PyExc_OSError);
index b4b39ec77b10c155ab73ede41e2d1b7ffa85cef1..44096f9fd19cb24fd73ddca7e4041cc5c7d2b409 100644 (file)
@@ -89,7 +89,7 @@ int pakfire_repo_refresh(struct pakfire_repo* repo, int force);
 
 // Compose
 
-int pakfire_repo_compose(struct pakfire* pakfire, const char* path, int flags,
+int pakfire_repo_compose(struct pakfire* pakfire, const char* path,
        const char** files);
 
 #ifdef PAKFIRE_PRIVATE
index 600d9d080abebb24d36b23b13885744f34b28247..f9c099a6df228b5ce547f6470bc16b0ee299212e 100644 (file)
@@ -1550,7 +1550,7 @@ ERROR:
 }
 
 PAKFIRE_EXPORT int pakfire_repo_compose(struct pakfire* pakfire, const char* path,
-               int flags, const char** files) {
+               const char** files) {
        struct pakfire_repo* repo = NULL;
        char realpath[PATH_MAX];
        char baseurl[PATH_MAX];
index b536e1da07a3216ece0c2447efe836e1eec54756..7bd32d7d91771af78e7f9c94c88adad42fc84fdc 100644 (file)
@@ -90,7 +90,7 @@ static int test_compose(const struct test* t) {
 
        // Compose the repository
        ASSERT_SUCCESS(
-               pakfire_repo_compose(t->pakfire, path, 0, files)
+               pakfire_repo_compose(t->pakfire, path, files)
        );
 
        // Everything passed