![]() |
abrt
2.14.2
A tool to inform users about various problems on the running system
|
#include <regex.h>
#include <gio/gio.h>
#include "abrt-dbus.h"
#include <libreport/internal_libreport.h>
#include "hooklib.h"
Go to the source code of this file.
Data Structures | |
struct | abrt_koops_line_info |
Macros | |
#define | ARRAY_SIZE(x) ((unsigned)(sizeof(x) / sizeof((x)[0]))) |
Typedefs | |
typedef struct ignored_problems | ignored_problems_t |
Enumerations | |
enum | { DD_PERM_EVENTS = 1 << 0, DD_PERM_DAEMONS = 1 << 1 } |
Functions | |
int | abrt_low_free_space (unsigned setting_MaxCrashReportsSize, const char *dump_location) |
Checks if there is enough free space to store the problem data. More... | |
void | abrt_trim_problem_dirs (const char *dirname, double cap_size, const char *exclude_path) |
void | abrt_ensure_writable_dir_uid_gid (const char *dir, mode_t mode, uid_t uid, gid_t gid) |
void | abrt_ensure_writable_dir (const char *dir, mode_t mode, const char *user) |
void | abrt_ensure_writable_dir_group (const char *dir, mode_t mode, const char *user, const char *group) |
char * | abrt_run_unstrip_n (const char *dump_dir_name, unsigned timeout_sec) |
char * | abrt_get_backtrace (const char *dump_dir_name, unsigned timeout_sec, const char *debuginfo_dirs) |
bool | abrt_dir_is_in_dump_location (const char *dir_name) |
bool | abrt_dir_has_correct_permissions (const char *dir_name, int flags) |
bool | abrt_new_user_problem_entry_allowed (uid_t uid, const char *name, const char *value) |
int | abrt_load_abrt_conf (void) |
void | abrt_free_abrt_conf_data (void) |
int | abrt_load_abrt_conf_file (const char *file, map_string_t *settings) |
int | abrt_load_abrt_plugin_conf_file (const char *file, map_string_t *settings) |
int | abrt_save_abrt_conf_file (const char *file, map_string_t *settings) |
int | abrt_save_abrt_plugin_conf_file (const char *file, map_string_t *settings) |
void | migrate_to_xdg_dirs (void) |
int | check_recent_crash_file (const char *filename, const char *executable) |
int | abrt_daemon_is_ok (void) |
void | abrt_notify_new_path (const char *path) |
Sends notification to abrtd that a new problem has been detected. More... | |
int | abrt_notify_new_path_with_response (const char *path, char **message) |
Sends notification to abrtd that a new problem has been detected and wait for the reply. More... | |
char * | abrt_koops_extract_version (const char *line) |
char * | abrt_kernel_tainted_short (const char *kernel_bt) |
char * | abrt_kernel_tainted_long (const char *tainted_short) |
char * | abrt_koops_hash_str_ext (const char *oops_buf, int frame_count, int duphas_flags) |
char * | abrt_koops_hash_str (const char *oops_buf) |
int | abrt_koops_line_skip_level (const char **c) |
void | abrt_koops_line_skip_jiffies (const char **c) |
void | abrt_koops_extract_oopses_from_lines (GList **oops_list, const struct abrt_koops_line_info *lines_info, int lines_info_size) |
void | abrt_koops_extract_oopses (GList **oops_list, char *buffer, size_t buflen) |
GList * | abrt_koops_suspicious_strings_list (void) |
GList * | abrt_koops_suspicious_strings_blacklist (void) |
void | abrt_koops_print_suspicious_strings (void) |
void | abrt_koops_print_suspicious_strings_filtered (const regex_t **filterout) |
int | chown_dir_over_dbus (const char *problem_dir_path) |
Changes the access rights of the problem specified by problem id. More... | |
int | test_exist_over_dbus (const char *problem_id, const char *element_name) |
Checks whether the given element name exists. More... | |
int | dbus_problem_is_complete (const char *problem_id) |
Checks whether the problem corresponding to the given ID is complete. More... | |
char * | load_text_over_dbus (const char *problem_id, const char *element_name) |
int | delete_problem_dirs_over_dbus (const GList *problem_dir_paths) |
Delets multiple problems specified by their id (as returned from problem_data_save) More... | |
int | fill_problem_data_over_dbus (const char *problem_dir_path, const char **elements, problem_data_t *problem_data) |
Fetches given problem elements for specified problem id. More... | |
problem_data_t * | get_problem_data_dbus (const char *problem_dir_path) |
Fetches problem information for specified problem id. More... | |
problem_data_t * | get_full_problem_data_over_dbus (const char *problem_dir_path) |
Fetches full problem data for specified problem id. More... | |
GList * | get_problems_over_dbus (bool authorize) |
Fetches all problems from problem database. More... | |
ignored_problems_t * | ignored_problems_new (char *file_path) |
Initializes a new instance of ignored problems. More... | |
void | ignored_problems_free (ignored_problems_t *set) |
Destroys an instance of ignored problems. More... | |
void | ignored_problems_add (ignored_problems_t *set, const char *problem_id) |
Adds a problem to the ignored problems. More... | |
void | ignored_problems_remove (ignored_problems_t *set, const char *problem_id) |
Removes a problem from the ignored problems. More... | |
bool | ignored_problems_contains (ignored_problems_t *set, const char *problem_id) |
Checks if a problem is in the ignored problems. More... | |
void | ignored_problems_add_problem_data (ignored_problems_t *set, problem_data_t *pd) |
Adds a problem defined by its data to the ignored problems. More... | |
void | ignored_problems_remove_problem_data (ignored_problems_t *set, problem_data_t *pd) |
Removes a problem defined by its data from the ignored problems. More... | |
bool | ignored_problems_contains_problem_data (ignored_problems_t *set, problem_data_t *pd) |
Checks if a problem defined its data is in the ignored problems. More... | |
void abrt_koops_print_suspicious_strings_filtered | ( | const regex_t ** | filterout | ) |
Prints all suspicious strings that do not match any of the regular expression in NULL terminated list.
The regular expression should be compiled with REG_NOSUB flag.
int abrt_low_free_space | ( | unsigned | setting_MaxCrashReportsSize, |
const char * | dump_location | ||
) |
Checks if there is enough free space to store the problem data.
setting_MaxCrashReportsSize | Maximum data size |
dump_location | Location to check for the available space |
void abrt_notify_new_path | ( | const char * | path | ) |
Sends notification to abrtd that a new problem has been detected.
[in] | path | Path to the problem directory containing the problem data |
int abrt_notify_new_path_with_response | ( | const char * | path, |
char ** | message | ||
) |
Sends notification to abrtd that a new problem has been detected and wait for the reply.
path | Path to the problem directory containing the problem data |
message | The abrtd reply |
int chown_dir_over_dbus | ( | const char * | problem_dir_path | ) |
Changes the access rights of the problem specified by problem id.
Requires authorization
int dbus_problem_is_complete | ( | const char * | problem_id | ) |
Checks whether the problem corresponding to the given ID is complete.
Might require authorization
int delete_problem_dirs_over_dbus | ( | const GList * | problem_dir_paths | ) |
Delets multiple problems specified by their id (as returned from problem_data_save)
problem_dir_paths | List of problem ids |
int fill_problem_data_over_dbus | ( | const char * | problem_dir_path, |
const char ** | elements, | ||
problem_data_t * | problem_data | ||
) |
Fetches given problem elements for specified problem id.
problem_data_t* get_full_problem_data_over_dbus | ( | const char * | problem_dir_path | ) |
Fetches full problem data for specified problem id.
problem_data_t* get_problem_data_dbus | ( | const char * | problem_dir_path | ) |
Fetches problem information for specified problem id.
GList* get_problems_over_dbus | ( | bool | authorize | ) |
Fetches all problems from problem database.
authorize | If set to true will try to fetch even problems owned by other users (will require root authorization over policy kit) |
void ignored_problems_add | ( | ignored_problems_t * | set, |
const char * | problem_id | ||
) |
Adds a problem to the ignored problems.
This function never fails. All errors will be logged.
set | An instance of ignored problems to which the problem will be added |
problem_id | An identifier of a problem which will be added to an ignored set |
void ignored_problems_add_problem_data | ( | ignored_problems_t * | set, |
problem_data_t * | pd | ||
) |
Adds a problem defined by its data to the ignored problems.
This function never fails. All errors will be logged.
set | An instance of ignored problems to which the problem will be added |
pd | A data of a problem which will be added to an ignored set |
bool ignored_problems_contains | ( | ignored_problems_t * | set, |
const char * | problem_id | ||
) |
Checks if a problem is in the ignored problems.
This function never fails. All errors will be logged. If any error occurs, the function returns 0 value.
set | An instance of ignored problems in which the problem will be searched |
problem_id | An identifier of a problem |
bool ignored_problems_contains_problem_data | ( | ignored_problems_t * | set, |
problem_data_t * | pd | ||
) |
Checks if a problem defined its data is in the ignored problems.
This function never fails. All errors will be logged. If any error occurs, the function returns 0 value.
set | An instance of ignored problems in which the problem will be searched |
pd | A data of a problem |
void ignored_problems_free | ( | ignored_problems_t * | set | ) |
Destroys an instance of ignored problems.
This function never fails. Supports the common behaviour where it accepts NULL pointers.
set | A destroyed instance |
ignored_problems_t* ignored_problems_new | ( | char * | file_path | ) |
Initializes a new instance of ignored problems.
file_path | A malloced string holding a path to a file containing the list of ignored problems. Function takes ownership of the malloced memory, which will be freed in ignored_problems_free() |
void ignored_problems_remove | ( | ignored_problems_t * | set, |
const char * | problem_id | ||
) |
Removes a problem from the ignored problems.
This function never fails. All errors will be logged.
set | An instance of ignored problems from which the problem will be deleted |
problem_id | An identifier of a problem which will be removed from an ignored problems struct |
void ignored_problems_remove_problem_data | ( | ignored_problems_t * | set, |
problem_data_t * | pd | ||
) |
Removes a problem defined by its data from the ignored problems.
This function never fails. All errors will be logged.
set | An instance of ignored problems from which the problem will be deleted |
pd | A data of a problem which will be removed from an ignored problems struct |
char* load_text_over_dbus | ( | const char * | problem_id, |
const char * | element_name | ||
) |
@ Returns value of the given element name
Might require authorization
int test_exist_over_dbus | ( | const char * | problem_id, |
const char * | element_name | ||
) |
Checks whether the given element name exists.
Might require authorization