[vlc-commits] keystore: use entry without path as a last resort

Thomas Guillem git at videolan.org
Sat Feb 13 16:38:17 CET 2016


vlc | branch: master | Thomas Guillem <thomas at gllm.fr> | Sat Feb 13 16:37:47 2016 +0100| [cc03fb961f09df824ab6d5238f3adfd7509ef380] | committer: Thomas Guillem

keystore: use entry without path as a last resort

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=cc03fb961f09df824ab6d5238f3adfd7509ef380
---

 src/misc/keystore.c |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/src/misc/keystore.c b/src/misc/keystore.c
index 638fab5..3430b51 100644
--- a/src/misc/keystore.c
+++ b/src/misc/keystore.c
@@ -137,7 +137,8 @@ find_closest_path(vlc_keystore_entry *p_entries, unsigned i_count,
         const char *psz_entry_path = p_entry->ppsz_values[KEY_PATH];
         if (psz_entry_path == NULL)
         {
-            p_match_entry = p_entry;
+            if (p_match_entry == NULL)
+                p_match_entry = p_entry;
             continue;
         }
         size_t i_entry_pathlen = strlen(psz_entry_path);



More information about the vlc-commits mailing list