[PATCH 2/4] Move is_number_in_set prototype to filter.h
Dmitry V. Levin
ldv at altlinux.org
Wed Aug 23 01:05:15 UTC 2017
On Tue, Aug 22, 2017 at 09:37:38AM +0700, Nikolay Marchuk wrote:
> On 22.08.2017 01:23, Edgar Kaziakhmedov wrote:
> > On Mon, Aug 21, 2017 at 07:21:44PM +0300, Dmitry V. Levin wrote:
> > > On Mon, Aug 21, 2017 at 03:06:57AM +0300, Edgar Kaziakhmedov wrote:
> > > > Since the filter.h unites set of filtering functions and defs.h contains
> > > > superfluous and unrelated set of prototypes, is_number_in_set
> > > > should be prototyped there. Also, other binaries included in the strace
> > > > package requires it for filtering.
> > > >
> > > > Signed-off-by: Edgar Kaziakhmedov <edgar.kaziakhmedov at virtuozzo.com>
> > > > ---
> > > > defs.h | 2 +-
> > > > filter.h | 1 +
> > > > 2 files changed, 2 insertions(+), 1 deletion(-)
> > > >
> > > > diff --git a/defs.h b/defs.h
> > > > index dddad0c9..9aba72ff 100644
> > > > --- a/defs.h
> > > > +++ b/defs.h
> > > > @@ -54,6 +54,7 @@
> > > > #include <sys/time.h>
> > > >
> > > > #include "error_prints.h"
> > > > +#include "filter.h"
> > > Why do you think it should be included here?
> > Because it is required by strace.c and syscall.c, that in turn have already included defs.h
> >
> Definitions in filter.h are designed for internal use by filtering. (And maybe to manipulate filtering)
> I don't think it is a good idea to expose all this definitions in either defs.h or syscall.c. And is_number_in_set is also used in
> signal filtering and in Victor's advanced tampering. Maybe you should add extern definition in your code to
> use it.
Now you can include "number_set.h" and link with number_set.c.
--
ldv
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 801 bytes
Desc: not available
URL: <http://lists.strace.io/pipermail/strace-devel/attachments/20170823/4d2870aa/attachment.bin>
More information about the Strace-devel
mailing list