[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#692133: [squeeze] struct rfkill_event with broken __packed flag



Package: linux-libc-dev
Version: 2.6.32-46

The file /usr/include/linux/rfkill.h has the following declaration:

struct rfkill_event {
        __u32 idx;
        __u8  type;
        __u8  op;
        __u8  soft, hard;
} __packed;

However, __packed is not declared and this declaration is actually a
definition of both the struct rfkill_event and a variable __packed.

This causes problems in two ways:

- structure definition is not necessarily packed
- I got duplicate definitions of the __packed variable in some of my own
code

Package version 3.2.23-1~bpo60+2 which can be found in debian-backports
doesn't have this bug, there the correct __attribute__ ((packed)) is used.

Here is a trivial example:

$ cat test.c
#include <linux/rfkill.h>
$ gcc -c -o test.o test.c
$ nm test.o
0000000000000008 C __packed


	Torsten


Reply to: