Blame SOURCES/autofs-5.1.7-fix-double-free-in-parse_mapent.patch
|
|
96dc52 |
autofs-5.1.7 - fix double free in parse_mapent()
|
|
|
96dc52 |
|
|
|
96dc52 |
From: Ian Kent <raven@themaw.net>
|
|
|
96dc52 |
|
|
|
96dc52 |
Coverity:
|
|
|
96dc52 |
in parse_mapent(): double_free: Calling "free" frees pointer "newopt"
|
|
|
96dc52 |
which has already been freed.
|
|
|
96dc52 |
|
|
|
96dc52 |
Signed-off-by: Ian Kent <raven@themaw.net>
|
|
|
96dc52 |
---
|
|
|
96dc52 |
CHANGELOG | 1 +
|
|
|
96dc52 |
modules/parse_sun.c | 2 --
|
|
|
96dc52 |
2 files changed, 1 insertion(+), 2 deletions(-)
|
|
|
96dc52 |
|
|
|
96dc52 |
diff --git a/CHANGELOG b/CHANGELOG
|
|
|
96dc52 |
index ff3d88eb..81461978 100644
|
|
|
96dc52 |
--- a/CHANGELOG
|
|
|
96dc52 |
+++ b/CHANGELOG
|
|
|
96dc52 |
@@ -62,6 +62,7 @@
|
|
|
96dc52 |
- fix dead code in mnts_add_mount().
|
|
|
96dc52 |
- fix arg not used in error print.
|
|
|
96dc52 |
- fix missing lock release in mount_subtree().
|
|
|
96dc52 |
+- fix double free in parse_mapent().
|
|
|
96dc52 |
|
|
|
96dc52 |
25/01/2021 autofs-5.1.7
|
|
|
96dc52 |
- make bind mounts propagation slave by default.
|
|
|
96dc52 |
diff --git a/modules/parse_sun.c b/modules/parse_sun.c
|
|
|
96dc52 |
index 5d15f892..03a63290 100644
|
|
|
96dc52 |
--- a/modules/parse_sun.c
|
|
|
96dc52 |
+++ b/modules/parse_sun.c
|
|
|
96dc52 |
@@ -974,8 +974,6 @@ static int parse_mapent(const char *ent, char *g_options, char **options, char *
|
|
|
96dc52 |
estr = strerror_r(errno, buf, MAX_ERR_BUF);
|
|
|
96dc52 |
error(logopt, MODPREFIX
|
|
|
96dc52 |
"concat_options: %s", estr);
|
|
|
96dc52 |
- if (newopt)
|
|
|
96dc52 |
- free(newopt);
|
|
|
96dc52 |
free(myoptions);
|
|
|
96dc52 |
return 0;
|
|
|
96dc52 |
}
|