Ticket #193 (closed defect: fixed)

Opened 3 years ago

Last modified 3 years ago

abrt-cli -l should not show reported cases

Reported by: mnowak Owned by: vda
Priority: major Milestone:
Component: abrt-cli Version: 2.0
Keywords: Cc:
Blocked By: Blocking:

Description

I just reported gcalctool problem to Bugzilla, Mailx and Logger (https://bugzilla.redhat.com/show_bug.cgi?id=692568), I entered abrt-cli -l and I still can see it:

[newman@dhcp-24-178 ~]$ abrt-cli -l
0.
	Crash dump : /home/newman/.abrt/spool/ccpp-2011-03-31-17:18:09-30289
	UID        : 501
	Package    : gcalctool-5.91.93-1
	Executable : /usr/bin/gcalctool
	Crash Time : Thu 31 Mar 2011 05:18:09 PM CEST
	Crash Count: 1
	Hostname   : dhcp-24-178.brq.redhat.com

I believe I should see this issue only with -l -f options.

Attachments

abrt-cli.l.log (12.6 KB) - added by mnowak 3 years ago.
Log from reporting to Bugzilla, Mailx, and Logger

Change History

Changed 3 years ago by mnowak

Log from reporting to Bugzilla, Mailx, and Logger

comment:1 Changed 3 years ago by mnowak

I noticed the crash dir moved from /var/spool/abrt/ccpp-2011-03-31-17:18:09-30289 to /home/newman/.abrt/spool/ccpp-2011-03-31-17:18:09-30289, maybe that's part of the issue?

comment:2 Changed 3 years ago by vda

  • Owner changed from kklic@… to vda
  • Status changed from new to assigned

comment:3 Changed 3 years ago by vda

Proposed fix:

--- abrt.1/src/plugins/abrt-action-kerneloops.c 2011-03-26 04:56:39.000000000 +0100 +++ abrt.2/src/plugins/abrt-action-kerneloops.c 2011-04-08 12:24:41.766669876 +0200 @@ -115,6 +115,15 @@ static void report_to_kerneloops(

+ dd = dd_opendir(dump_dir_name, /*flags:*/ 0); + if (dd) + { + char *msg = xasprintf("kerneloops: URL=%s", submitURL); + add_reported_to(dd, msg); + free(msg); + dd_close(dd); + } +

log("Kernel oops report was uploaded");

}

--- abrt.1/src/plugins/abrt-action-mailx.c 2011-03-25 16:22:47.000000000 +0100 +++ abrt.2/src/plugins/abrt-action-mailx.c 2011-04-08 12:23:01.288920151 +0200 @@ -118,6 +118,14 @@ static void create_and_send_email(

free_crash_data(crash_data);

+ dd = dd_opendir(dump_dir_name, /*flags:*/ 0); + if (dd) + { + char *msg = xasprintf("email: %s", email_to); + add_reported_to(dd, msg); + free(msg); + dd_close(dd); + }

log("Email was sent to: %s", email_to);

}

--- abrt.1/src/plugins/abrt-action-rhtsupport.c 2011-03-25 16:02:16.000000000 +0100 +++ abrt.2/src/plugins/abrt-action-rhtsupport.c 2011-04-08 12:21:44.553920601 +0200 @@ -221,7 +221,16 @@ static void report_to_rhtsupport(

/* Use sanitized string as error message */ error_msg_and_die("%s", result);

}

+

/* No error */

+ dd = dd_opendir(dump_dir_name, /*flags:*/ 0); + if (dd) + { + char *msg = xasprintf("RHTSupport: %s", result); + add_reported_to(dd, msg); + free(msg); + dd_close(dd); + }

log("%s", result); free(result);

}

comment:4 Changed 3 years ago by vda

The patch above adds a line to "reported_to" element in the directory for RHTSupport and Mailx.

I hesitate to add the same to Logger reporter because it doesn't really send the data anywhere, it's usually for debugging. Do you think Logger should add such line too?

comment:5 Changed 3 years ago by vda

Pushed to git

comment:6 Changed 3 years ago by vda

  • Resolution set to fixed
  • Status changed from assigned to closed

Added -r option to abrt-action-print to make it possible for Logger to record reported_to:

abrt-action-print -o "${Log_File:-/tmp/abrt.log}" -a "${Append:-no}" -r

comment:7 Changed 3 years ago by vda

  • Summary changed from `abrt-cli -l` should not show reported cases to abrt-cli -l should not show reported cases

comment:8 Changed 3 years ago by anonymous

  • Milestone 2.0.1 deleted

Milestone 2.0.1 deleted

Note: See TracTickets for help on using tickets.