[lxc-devel] [PATCH] Changed double check in if for "[x86_64]"

S.Çağlar Onur caglar at 10ur.org
Sat Jul 18 22:10:42 UTC 2015


Hi Thomas,

FYI, It's not checking the same string twice, notice the case change (X86
vs x86)

Best,

On Sat, Jul 18, 2015 at 4:28 PM Thomas Lamprecht <t.lamprecht at proxmox.com>
wrote:

> Instead of checking if it's "[x86_64]" twice,
> check for "[x86_64]" or "[amd64]"
> Signed-off-by: Thomas Lamprecht <t.lamprecht at proxmox.com>
>
> Signed-off-by: Thomas Lamprecht <t.lamprecht at proxmox.com>
> ---
>  src/lxc/seccomp.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/src/lxc/seccomp.c b/src/lxc/seccomp.c
> index 108faa0..374d54f 100644
> --- a/src/lxc/seccomp.c
> +++ b/src/lxc/seccomp.c
> @@ -333,7 +333,7 @@ static int parse_config_v2(FILE *f, char *line, struct
> lxc_conf *conf)
>                                                 goto bad;
>                                 }
>                         } else if (strcmp(line, "[X86_64]") == 0 ||
> -                                       strcmp(line, "[x86_64]") == 0) {
> +                                       strcmp(line, "[amd64]") == 0) {
>                                 if (native_arch != lxc_seccomp_arch_amd64)
> {
>                                         cur_rule_arch =
> lxc_seccomp_arch_unknown;
>                                         continue;
> --
> 2.4.5
>
> _______________________________________________
> lxc-devel mailing list
> lxc-devel at lists.linuxcontainers.org
> http://lists.linuxcontainers.org/listinfo/lxc-devel
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.linuxcontainers.org/pipermail/lxc-devel/attachments/20150718/d3dbd710/attachment.html>


More information about the lxc-devel mailing list