Commit Graph

5 Commits

Author SHA1 Message Date
b93d52fe3d Change the license of strace to LGPL-2.1-or-later
strace is now provided under the terms of the GNU Lesser General
Public License version 2.1 or later, see COPYING for more details.

strace test suite is now provided under the terms of the GNU General
Public License version 2 or later, see tests/COPYING for more details.
2018-12-10 00:00:00 +00:00
1998f2666a alloc_number_set_array: add ATTRIBUTE_MALLOC
* number_set.h: Include "gcc_compat.h".
(alloc_number_set_array): Add ATTRIBUTE_MALLOC.
2017-08-24 18:24:16 +00:00
5d7623a502 Hide struct number_set implementation details from users
* number_set.h (number_slot_t, struct number_set): Move to number_set.c.
(struct number_set): Add forward declaration.
(read_set, write_set, signal_set): Change prototypes from objects
to pointers.
* filter_qualify.c (read_set, write_set, signal_set): Change definitions
from objects to pointers.
(abbrev_set, inject_set, raw_set, trace_set, verbose_set): Change
definitions from arrays to pointers.
(qualify_read): Initialize read_set before first use.
(qualify_write): Initialize write_set before first use.
(qualify_signals): Initialize signal_set before first use.
(qualify_trace): Initialize trace_set before first use.
(qualify_abbrev): Initialize abbrev_set before first use.
(qualify_verbose): Initialize verbose_set before first use.
(qualify_raw): Initialize raw_set before first use.
(qualify_inject_common): Initialize inject_set before first use.
* strace.c (print_signalled, print_stopped): Update signal_set usage.
* syscall.c (dumpio): Update usage of read_set and write_set.
2017-08-22 21:23:49 +00:00
ef7b7a70c1 Extend number_set interface
* number_set.h (number_set_array_is_empty, is_number_in_set_array,
add_number_to_set_array, clear_number_set_array,
invert_number_set_array, alloc_number_set_array, free_number_set_array):
New function prototypes.
* number_set.c (number_set_array_is_empty, is_number_in_set_array,
add_number_to_set_array, clear_number_set_array,
invert_number_set_array, alloc_number_set_array, free_number_set_array):
New functions.
* basic_filters.c (qualify_syscall_number, qualify_syscall_regex,
qualify_syscall_class, qualify_syscall_name): Use
add_number_to_set_array.
(qualify_syscall_tokens, qualify_tokens): Use
clear_number_set_array and invert_number_set_array.
* filter_qualify.c (qualify_inject_common): Use alloc_number_set_array,
number_set_array_is_empty, is_number_in_set_array,
add_number_to_set_array, and free_number_set_array.
(qual_flags): Use is_number_in_set_array.
2017-08-22 21:23:49 +00:00
67c97082ac Move number_set interface to separate files
* number_set.c: New file.
* number_set.h: Likewise.
* Makefile.am (strace_SOURCES): Add them.
* basic_filters.c: Include "number_set.h".
(number_slot_t, struct number_set): Move to number_set.h.
(BITS_PER_SLOT, number_setbit, number_isset, reallocate_number_set,
add_number_to_set, is_number_in_set): Move to number_set.c.
* defs.h (struct number_set): Remove forward declaration.
(read_set, write_set, signal_set, is_number_in_set): Move to number_set.h.
* filter.h (add_number_to_set): Move to number_set.h.
* filter_qualify.c: Include "number_set.h".
(number_slot_t, struct number_set): Remove.
* strace.c: Include "number_set.h".
* syscall.c: Likewise.
2017-08-22 21:23:49 +00:00