|
|
f4add2 |
autofs-5.1.3 - revert fix argc off by one in mount_autofs.c
|
|
|
f4add2 |
|
|
|
f4add2 |
From: Ian Kent <raven@themaw.net>
|
|
|
f4add2 |
|
|
|
f4add2 |
Commit 6a44f715cf to fix an off by one error in the arguments calculation
|
|
|
f4add2 |
when mounting an autofs submount actually introduced an off by one error
|
|
|
f4add2 |
instead of fixing one.
|
|
|
f4add2 |
|
|
|
f4add2 |
Revert the change.
|
|
|
f4add2 |
|
|
|
f4add2 |
Signed-off-by: Ian Kent <raven@themaw.net>
|
|
|
f4add2 |
---
|
|
|
f4add2 |
CHANGELOG | 1 +
|
|
|
f4add2 |
modules/mount_autofs.c | 8 ++++----
|
|
|
f4add2 |
2 files changed, 5 insertions(+), 4 deletions(-)
|
|
|
f4add2 |
|
|
|
f4add2 |
--- autofs-5.0.7.orig/CHANGELOG
|
|
|
f4add2 |
+++ autofs-5.0.7/CHANGELOG
|
|
|
f4add2 |
@@ -251,6 +251,7 @@
|
|
|
f4add2 |
- limit getgrgid_r() buffer size.
|
|
|
f4add2 |
- add congigure option for limiting getgrgid_r() stack usage.
|
|
|
f4add2 |
- fix unset tsd group name handling.
|
|
|
f4add2 |
+- revert fix argc off by one in mount_autofs.c.
|
|
|
f4add2 |
|
|
|
f4add2 |
25/07/2012 autofs-5.0.7
|
|
|
f4add2 |
=======================
|
|
|
f4add2 |
--- autofs-5.0.7.orig/modules/mount_autofs.c
|
|
|
f4add2 |
+++ autofs-5.0.7/modules/mount_autofs.c
|
|
|
f4add2 |
@@ -181,11 +181,11 @@ int mount_mount(struct autofs_point *ap,
|
|
|
f4add2 |
|
|
|
f4add2 |
if (options) {
|
|
|
f4add2 |
char *t = options;
|
|
|
f4add2 |
- while ((t = strchr(t, ',')) != NULL) {
|
|
|
f4add2 |
+ do {
|
|
|
f4add2 |
argc++;
|
|
|
f4add2 |
if (*t == ',')
|
|
|
f4add2 |
t++;
|
|
|
f4add2 |
- }
|
|
|
f4add2 |
+ } while ((t = strchr(t, ',')) != NULL);
|
|
|
f4add2 |
}
|
|
|
f4add2 |
argv = (const char **) alloca((argc + 1) * sizeof(char *));
|
|
|
f4add2 |
|
|
|
f4add2 |
@@ -213,13 +213,13 @@ int mount_mount(struct autofs_point *ap,
|
|
|
f4add2 |
|
|
|
f4add2 |
if (options) {
|
|
|
f4add2 |
p = options;
|
|
|
f4add2 |
- while ((p = strchr(p, ',')) != NULL) {
|
|
|
f4add2 |
+ do {
|
|
|
f4add2 |
if (*p == ',') {
|
|
|
f4add2 |
*p = '\0';
|
|
|
f4add2 |
p++;
|
|
|
f4add2 |
}
|
|
|
f4add2 |
argv[argc++] = p;
|
|
|
f4add2 |
- }
|
|
|
f4add2 |
+ } while ((p = strchr(p, ',')) != NULL);
|
|
|
f4add2 |
}
|
|
|
f4add2 |
argv[argc] = NULL;
|
|
|
f4add2 |
|