From ce4873a1f1c1fd40af0411bf5032cc5a29722db7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Piotr=20W=C3=B3jcik?= Date: Tue, 1 Oct 2019 21:18:25 +0200 Subject: [PATCH] Use predefined constant in place of magic string --- lib/plist_fetch.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/plist_fetch.c b/lib/plist_fetch.c index c80d4a5f..427fc7bb 100644 --- a/lib/plist_fetch.c +++ b/lib/plist_fetch.c @@ -196,12 +196,12 @@ xbps_repo_fetch_remote(struct xbps_repo *repo, const char *url) if (bfile[0] == '.') bfile++; /* skip first dot */ - if (strcmp(bfile, "index-meta.plist") == 0) { + if (strcmp(bfile, XBPS_REPOIDX_META) == 0) { buf = xbps_archive_get_file(a, entry); repo->idxmeta = xbps_dictionary_internalize(buf); free(buf); i++; - } else if (strcmp(bfile, "index.plist") == 0) { + } else if (strcmp(bfile, XBPS_REPOIDX) == 0) { buf = xbps_archive_get_file(a, entry); repo->idx = xbps_dictionary_internalize(buf); free(buf);