int main(int argc, char *argv[]) { _cleanup_free_ char *text = NULL; int r; setlocale(LC_ALL, "de_DE.UTF-8"); log_parse_environment(); log_open(); test_catalog_file_lang(); test_catalog_importing(); test_catalog_update(); r = catalog_list(stdout, database, true); assert_se(r >= 0); r = catalog_list(stdout, database, false); assert_se(r >= 0); assert_se(catalog_get(database, SD_MESSAGE_COREDUMP, &text) >= 0); printf(">>>%s<<<\n", text); if (database) unlink(database); return 0; }
int main(int argc, char *argv[]) { _cleanup_free_ char *text = NULL; setlocale(LC_ALL, "de_DE.UTF-8"); log_set_max_level(LOG_DEBUG); assert_se(catalog_update() >= 0); assert_se(catalog_list(stdout) >= 0); assert_se(catalog_get(SD_MESSAGE_COREDUMP, &text) >= 0); printf(">>>%s<<<\n", text); fflush(stdout); return 0; }