diff options
author | Phaedrus Leeds <mwleeds@protonmail.com> | 2021-05-02 21:52:49 -0500 |
---|---|---|
committer | Alexander Larsson <alexander.larsson@gmail.com> | 2021-05-04 10:23:13 +0200 |
commit | 4562627b0424ad381aa16975f77552b3e1afbaf3 (patch) | |
tree | cdaf6b5d6f5e0000e6312f1826925d6893bfecac | |
parent | 66d00e1c47b974d361cc777d7dc1d848ece42705 (diff) | |
download | flatpak-4562627b0424ad381aa16975f77552b3e1afbaf3.tar.gz |
utils: Add missing check for empty string collection id
-rw-r--r-- | common/flatpak-utils.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/common/flatpak-utils.c b/common/flatpak-utils.c index 90036c6d..ce2fdeb8 100644 --- a/common/flatpak-utils.c +++ b/common/flatpak-utils.c @@ -2307,6 +2307,8 @@ flatpak_parse_repofile (const char *remote_name, if (collection_id == NULL) collection_id = g_key_file_get_string (keyfile, source_group, FLATPAK_REPO_COLLECTION_ID_KEY, NULL); + if (collection_id != NULL && *collection_id == '\0') + g_clear_pointer (&collection_id, g_free); if (collection_id != NULL) { if (gpg_key == NULL) |