NAME | SYNOPSIS | API RESTRICTIONS | ARGUMENTS | DESCRIPTION | RETURN VALUES | ERRORS | ATTRIBUTES | SEE ALSO
$(OS_DIR)/lib/libblackbox.a #include <sys/blackbox.h>int bb_getfilters(bb_filter_t *filters, uint_t *nfilters);
The function or functions documented here may not be used safely in all application contexts with all APIs provided in the ChorusOS 5.0 product.
See API(5FEA) for details.
an array of nfilters bb_filter_ts
the number of bb_filter_ts passed in filters.
bb_getfilters() returns the filter list and the filtered severity bitmap for the node.
On successful return, filters will be filled in with the node's filter list and filtered severity bitmap. For each bb_filter_t returned:
The bbf_tag member is a string of maximum length BB_TAG_MAX characters, including the trailing \0
The bbf_severity member is a bitmap of severity levels between 0 and 31 inclusive. A given severity level can be tested for or modified with the BB_SEV_* interfaces.
If the bbf_tag member of a returned bb_filter_t matches the reserved tag BB_ALL_TAGS, the bbf_severity member is the filtered severity bitmap for the node. When calling bb_getfilters(), nfilters should point to the number of bb_filter_ts passed in filters. On successful return, nfilters will be updated with the total number of filters on the node, including 1 for the filtered severity bitmap (if it exists).
The caller can determine the number of filters on the node by passing a NULL filters value and a valid nfilters pointer, e.g. the address of an integer with value 0.
bb_getfilters() returns 0 on success and -1 on failure.
If it returns -1, the contents of filters and nfilters are undefined, and errno is set to:
The filters or nfilters argument points to an illegal address.
bb_getfilters() has been called within an interrupt context.
nfilters is greater than the maximum number of filters.
See attributes(5) for descriptions of the following attributes:
ATTRIBUTE TYPE | ATTRIBUTE VALUE |
---|---|
Interface Stability | Evolving |
NAME | SYNOPSIS | API RESTRICTIONS | ARGUMENTS | DESCRIPTION | RETURN VALUES | ERRORS | ATTRIBUTES | SEE ALSO