Re: [PATCH 2/2] tests: check decoding of NETLINK_SELINUX protocol

2017-07-14 Thread Dmitry V. Levin
On Sat, Jul 15, 2017 at 08:02:24AM +0800, JingPiao Chen wrote: > On Sat, Jul 15, 2017 at 02:45:01AM +0300, Dmitry V. Levin wrote: > > On Sat, Jul 15, 2017 at 12:22:57AM +0800, JingPiao Chen wrote: > > > On Fri, Jul 14, 2017 at 01:16:37PM +0800, JingPiao Chen wrote: > > > [...] > > > > +static void

Re: [PATCH 2/2] tests: check decoding of NETLINK_SELINUX protocol

2017-07-14 Thread JingPiao Chen
On Sat, Jul 15, 2017 at 02:45:01AM +0300, Dmitry V. Levin wrote: > On Sat, Jul 15, 2017 at 12:22:57AM +0800, JingPiao Chen wrote: > > On Fri, Jul 14, 2017 at 01:16:37PM +0800, JingPiao Chen wrote: > > [...] > > > +static void > > > +test_selnl_msg_setenforce(const int fd) > > > +{ > > > + void *con

Re: [PATCH 2/2] tests: check decoding of NETLINK_SELINUX protocol

2017-07-14 Thread Dmitry V. Levin
On Sat, Jul 15, 2017 at 12:22:57AM +0800, JingPiao Chen wrote: > On Fri, Jul 14, 2017 at 01:16:37PM +0800, JingPiao Chen wrote: > [...] > > +static void > > +test_selnl_msg_setenforce(const int fd) > > +{ > > + void *const nlh0 = tail_alloc(NLMSG_HDRLEN); > > + static char pattern[4096]; > > +

Re: [PATCH 2/2] tests: check decoding of NETLINK_SELINUX protocol

2017-07-14 Thread JingPiao Chen
On Fri, Jul 14, 2017 at 01:16:37PM +0800, JingPiao Chen wrote: [...] > +static void > +test_selnl_msg_setenforce(const int fd) > +{ > + void *const nlh0 = tail_alloc(NLMSG_HDRLEN); > + static char pattern[4096]; > + fill_memory_ex(pattern, sizeof(pattern), 'a', 'z' - 'a' + 1); > + > +