|
|
23b4c9 |
autofs-5.1.2 - fix invalid reference in remount_active_mount()
|
|
|
23b4c9 |
|
|
|
23b4c9 |
From: Ian Kent <raven@themaw.net>
|
|
|
23b4c9 |
|
|
|
23b4c9 |
remount_active_mount() can be called with the map entry pointer NULL
|
|
|
23b4c9 |
so it must be checked before use when getting the automount timeout.
|
|
|
23b4c9 |
|
|
|
23b4c9 |
Signed-off-by: Ian Kent <raven@themaw.net>
|
|
|
23b4c9 |
---
|
|
|
23b4c9 |
CHANGELOG | 1 +
|
|
|
23b4c9 |
lib/mounts.c | 6 ++++--
|
|
|
23b4c9 |
2 files changed, 5 insertions(+), 2 deletions(-)
|
|
|
23b4c9 |
|
|
|
23b4c9 |
--- autofs-5.0.7.orig/lib/mounts.c
|
|
|
23b4c9 |
+++ autofs-5.0.7/lib/mounts.c
|
|
|
23b4c9 |
@@ -1721,8 +1721,10 @@ static int remount_active_mount(struct a
|
|
|
23b4c9 |
if (fd == -1)
|
|
|
23b4c9 |
return REMOUNT_OPEN_FAIL;
|
|
|
23b4c9 |
|
|
|
23b4c9 |
- error(ap->logopt, "ap->type %d type %u", ap->type, type);
|
|
|
23b4c9 |
- timeout = get_exp_timeout(ap, me->source);
|
|
|
23b4c9 |
+ if (!me)
|
|
|
23b4c9 |
+ timeout = get_exp_timeout(ap, NULL);
|
|
|
23b4c9 |
+ else
|
|
|
23b4c9 |
+ timeout = get_exp_timeout(ap, me->source);
|
|
|
23b4c9 |
|
|
|
23b4c9 |
/* Re-reading the map, set timeout and return */
|
|
|
23b4c9 |
if (ap->state == ST_READMAP) {
|
|
|
23b4c9 |
--- autofs-5.0.7.orig/CHANGELOG
|
|
|
23b4c9 |
+++ autofs-5.0.7/CHANGELOG
|
|
|
23b4c9 |
@@ -246,6 +246,7 @@
|
|
|
23b4c9 |
- fix possible NULL derefernce.
|
|
|
23b4c9 |
- fix work around sss startup delay.
|
|
|
23b4c9 |
- improve scalability of direct mount path component.
|
|
|
23b4c9 |
+- fix invalid reference in remount_active_mount().
|
|
|
23b4c9 |
|
|
|
23b4c9 |
25/07/2012 autofs-5.0.7
|
|
|
23b4c9 |
=======================
|