From: Karel Zak Date: Fri, 26 Aug 2022 08:25:04 +0000 (+0200) Subject: libmount: remove unused context variables X-Git-Tag: v2.39-rc1~275 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=66defb745cb163149198a02ad9092f06fd49c443;p=thirdparty%2Futil-linux.git libmount: remove unused context variables All replaced by optlist container. Signed-off-by: Karel Zak --- diff --git a/libmount/src/context.c b/libmount/src/context.c index 1ca354f83b..b846a93035 100644 --- a/libmount/src/context.c +++ b/libmount/src/context.c @@ -154,15 +154,11 @@ int mnt_reset_context(struct libmnt_context *cxt) mnt_unref_table(cxt->utab); free(cxt->helper); - free(cxt->orig_user); cxt->fs = NULL; cxt->mountinfo = NULL; cxt->utab = NULL; cxt->helper = NULL; - cxt->orig_user = NULL; - cxt->mountflags = 0; - cxt->user_mountflags = 0; cxt->mountdata = NULL; cxt->flags = MNT_FL_DEFAULT; cxt->noautofs = 1; @@ -289,11 +285,6 @@ struct libmnt_context *mnt_copy_context(struct libmnt_context *o) goto failed; if (strdup_between_structs(n, o, helper)) goto failed; - if (strdup_between_structs(n, o, orig_user)) - goto failed; - - n->mountflags = o->mountflags; - n->mountdata = o->mountdata; n->map_linux = o->map_linux; n->map_userspace = o->map_userspace; diff --git a/libmount/src/mountP.h b/libmount/src/mountP.h index 51491eb2d7..799aeb2036 100644 --- a/libmount/src/mountP.h +++ b/libmount/src/mountP.h @@ -383,11 +383,8 @@ struct libmnt_context int optsmode; /* fstab optstr mode MNT_OPTSMODE_{AUTO,FORCE,IGNORE} */ - unsigned long mountflags; /* final mount(2) flags */ const void *mountdata; /* final mount(2) data, string or binary data */ - unsigned long user_mountflags; /* MNT_MS_* (loop=, user=, ...) */ - struct libmnt_cache *cache; /* paths cache */ struct libmnt_lock *lock; /* utab lock */ struct libmnt_update *update; /* utab update */ @@ -409,8 +406,6 @@ struct libmnt_context int helper_status; /* helper wait(2) status */ int helper_exec_status; /* 1: not called yet, 0: success, <0: -errno */ - char *orig_user; /* original (non-fixed) user= option */ - pid_t *children; /* "mount -a --fork" PIDs */ int nchildren; /* number of children */ pid_t pid; /* 0=parent; PID=child */