[vlc-commits] [Git][videolan/vlc][master] modules: fix invalid frees
Jean-Baptiste Kempf (@jbk)
gitlab at videolan.org
Fri Dec 31 11:58:45 UTC 2021
Jean-Baptiste Kempf pushed to branch master at VideoLAN / VLC
Commits:
cf16bd05 by Lyndon Brown at 2021-12-31T11:25:01+00:00
modules: fix invalid frees
- - - - -
1 changed file:
- src/modules/cache.c
Changes:
=====================================
src/modules/cache.c
=====================================
@@ -661,10 +661,13 @@ void CacheSave(vlc_object_t *p_this, const char *dir,
char *filename = NULL, *tmpname = NULL;
if (asprintf (&filename, "%s"DIR_SEP CACHE_NAME, dir ) == -1)
- goto out;
+ return;
if (asprintf (&tmpname, "%s.%"PRIu32, filename, (uint32_t)getpid ()) == -1)
- goto out;
+ {
+ free (filename);
+ return;
+ }
msg_Dbg (p_this, "saving plugins cache %s", filename);
FILE *file = vlc_fopen (tmpname, "wb");
View it on GitLab: https://code.videolan.org/videolan/vlc/-/commit/cf16bd0500e00b55ba39b38bf74a7c7f3deb5998
--
View it on GitLab: https://code.videolan.org/videolan/vlc/-/commit/cf16bd0500e00b55ba39b38bf74a7c7f3deb5998
You're receiving this email because of your account on code.videolan.org.
More information about the vlc-commits
mailing list