]> git.ipfire.org Git - pakfire.git/commitdiff
repo: Reset the package path after copying
authorMichael Tremer <michael.tremer@ipfire.org>
Tue, 8 Nov 2022 17:30:51 +0000 (17:30 +0000)
committerMichael Tremer <michael.tremer@ipfire.org>
Tue, 8 Nov 2022 17:30:51 +0000 (17:30 +0000)
We do not want to leave any trace about where the package was copied
from in the repository database.

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
src/libpakfire/repo.c

index f8597e9c282e9c4a1df268412ac485b134f8b509..2b72e317256daf170e6cb80355e4f2a4370806e4 100644 (file)
@@ -1568,10 +1568,8 @@ PAKFIRE_EXPORT int pakfire_repo_compose(struct pakfire* pakfire, const char* pat
                                goto OUT;
                        }
 
-                       const char* repo_path = pakfire_path_relpath(path, destination_path);
-
-                       // Update package location relative to the repository directory
-                       pakfire_package_set_string(package, PAKFIRE_PKG_PATH, repo_path);
+                       // Reset the path
+                       pakfire_package_set_string(package, PAKFIRE_PKG_PATH, NULL);
 
 OUT:
                        if (archive) {