Re: [PATCH] modpost: Fix modpost's license checking V2

From: Anders Kaseorg
Date: Tue Jul 12 2011 - 14:02:43 EST


On Tue, Jul 12, 2011 at 03:00, Alessio Igor Bogani <abogani@xxxxxxxxxx> wrote:
> +#define SEC_NAME_MATCH(name, str) (strncmp(name, str, strlen(str) - 1) == 0)

Surely you meant strlen() or sizeof() - 1, not strlen() - 1?

> + if (!is_vmlinux(mod->name) && strncmp(symname, "__ksymtab", 9) == 0)

Same strncmp pattern here. BTW, your macro is the strstarts()
function in include/linux/string.h.

Anders
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/