Debian Codegraph @

src/XCCDF_POLICY/reporter.c

raw symbols SCIP
1 /*
2 * Copyright 2014 Red Hat Inc., Durham, North Carolina.
3 * All Rights Reserved.
4 *
5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Lesser General Public
7 * License as published by the Free Software Foundation; either
8 * version 2.1 of the License, or (at your option) any later version.
9 *
10 * This library is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 * Lesser General Public License for more details.
14 *
15 * You should have received a copy of the GNU Lesser General Public
16 * License along with this library; if not, write to the Free Software
17 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
18 *
19 * Authors:
20 * Šimon Lukašík
21 */
22
23 #ifdef HAVE_CONFIG_Hcxx . . $ `<built-in>:409:9`!
24 #include <config.h>cxx . . $ `<file>/build/config.h`/
25 #endif
26
27 #include "common/util.h"cxx . . $ `<file>/src/common/util.h`/
28 #include "public/xccdf_policy.h"cxx . . $ `<file>/src/XCCDF_POLICY/public/xccdf_policy.h`/
29 #include "reporter_priv.h"cxx . . $ `<file>/src/XCCDF_POLICY/reporter_priv.h`/
30
31 struct reportercxx . . $ reporter# {
32 char * systemcxx . . $ reporter#system.; ///< Identificator of checking engine (output engine)
33 int (*callbackcxx . . $ reporter#callback.)(void*,void*); ///< policy report callback {output,start}
34 void * usrcxx . . $ reporter#usr.; ///< User data structure
35 };
36
37 struct reportercxx . . $ reporter# *reporter_newcxx . . $ reporter_new(862f20392162f96e).(char *report_type, void *output_func, void *usr)
38 {
39 struct reportercxx . . $ reporter# *reporter = malloccxx . . $ malloc(bfcfa4d6b7f7ef64).(sizeof(struct reportercxx . . $ reporter#));
40 if (reporter != NULLcxx . . $ `<external>/15298297234472979974/stddef.h:419:9`!) {
41 reporter->systemcxx . . $ reporter#system. = report_type;
42 reporter->callbackcxx . . $ reporter#callback. = output_func;
43 reporter->usrcxx . . $ reporter#usr. = usr;
44 }
45 return reporter;
46 }
47
48 int reporter_send_simplecxx . . $ reporter_send_simple(f04c68df167aa33).(struct reportercxx . . $ reporter# *reporter, void *data)
49 {
50 return reporter->callbackcxx . . $ reporter#callback.(data, reporter->usrcxx . . $ reporter#usr.);
51 }