Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
}
static void modinfo(const char *path, const char *version,
- struct modinfo_env *env)
+ const struct modinfo_env *env)
{
static const char *const shortcuts[] = {
"filename",
if (field)
tags |= OPT_F;
for (j = 1; (1<<j) & (OPT_TAGS + OPT_F); j++) {
- const char *pattern = field;
- if ((1<<j) & OPT_TAGS)
- pattern = shortcuts[j];
+ const char *pattern;
+
if (!((1<<j) & tags))
continue;
+ pattern = field;
+ if ((1<<j) & OPT_TAGS)
+ pattern = shortcuts[j];
length = strlen(pattern);
ptr = the_module;
while (1) {