]> git.ipfire.org Git - pakfire.git/commitdiff
repo: Use our own string comparison function
authorMichael Tremer <michael.tremer@ipfire.org>
Wed, 26 Mar 2025 15:46:12 +0000 (15:46 +0000)
committerMichael Tremer <michael.tremer@ipfire.org>
Wed, 26 Mar 2025 15:46:12 +0000 (15:46 +0000)
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
src/pakfire/repo.c

index 3dee18e0c02e77e3867839af508e0cbc57df97dd..c0b18fb21e0ca664dba0ad49767ab610f2605991 100644 (file)
@@ -183,7 +183,7 @@ int pakfire_repo_name_equals(struct pakfire_repo* repo, const char* name) {
        if (!n)
                return 0;
 
-       return strcmp(n, name) == 0;
+       return pakfire_string_equals(n, name);
 }
 
 char* pakfire_repo_url_replace(struct pakfire_repo* repo, const char* url) {
@@ -223,7 +223,7 @@ char* pakfire_repo_url_replace(struct pakfire_repo* repo, const char* url) {
        }
 
 #ifdef ENABLE_DEBUG
-       if (strcmp(url, buffer) != 0) {
+       if (!pakfire_string_equals(url, buffer)) {
                DEBUG(repo->ctx, "Repository URL updated:");
                DEBUG(repo->ctx, "  From: %s\n", url);
                DEBUG(repo->ctx, "  To  : %s\n", buffer);
@@ -1573,7 +1573,7 @@ int pakfire_repo_cmp(struct pakfire_repo* repo1, struct pakfire_repo* repo2) {
        else if (r1->priority < r2->priority)
                return -1;
 
-       return strcmp(r1->name, r2->name);
+       return pakfire_string_equals(r1->name, r2->name);
 }
 
 int pakfire_repo_count(struct pakfire_repo* repo) {