From a756114f9d29983d9505309efb3b6f0ed09f946f Mon Sep 17 00:00:00 2001 From: Denys Vlasenko Date: Thu, 3 Dec 2009 17:43:18 +0100 Subject: hopefully fix rhbz#541854: when we trim the dir, we must delete it from DB too Also added a more robust code to resis SEGVing if directory doesn't exist. Signed-off-by: Denys Vlasenko --- src/Daemon/Daemon.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/Daemon/Daemon.cpp') diff --git a/src/Daemon/Daemon.cpp b/src/Daemon/Daemon.cpp index c2d2265..4cfd049 100644 --- a/src/Daemon/Daemon.cpp +++ b/src/Daemon/Daemon.cpp @@ -474,7 +474,8 @@ static gboolean handle_inotify_cb(GIOChannel *gio, GIOCondition condition, gpoin ) { log("Size of '%s' >= %u MB, deleting '%s'", DEBUG_DUMPS_DIR, g_settings_nMaxCrashReportsSize, worst_dir.c_str()); g_pCommLayer->QuotaExceed(_("Report size exceeded the quota. Please check system's MaxCrashReportsSize value in abrt.conf.")); - delete_debug_dump_dir(concat_path_file(DEBUG_DUMPS_DIR, worst_dir.c_str()).c_str()); + /* deletes both directory and DB record */ + DeleteDebugDump_by_dir(concat_path_file(DEBUG_DUMPS_DIR, worst_dir.c_str()).c_str()); worst_dir = ""; } -- cgit