On 08/02/2011 04:01 PM, Jiri Moskovcak wrote:
On 08/02/2011 03:56 PM, Jiri Moskovcak wrote:
On 08/02/2011 03:42 PM, Denys Vlasenko wrote:
On Fri, 2011-07-22 at 13:37 +0200, Miroslav Lichvar wrote:
+char *format_report_result(const struct report_result *result) +{
- const char *type_string;
- switch (result->type)
- {
- case REPORT_RESULT_TYPE_URL:
- type_string = "URL";
- break;
- case REPORT_RESULT_TYPE_MESSAGE:
- type_string = "MSG";
- break;
- default:
- assert(0);
- }
- return xasprintf("%s: TIME=%s %s=%s", result->event,
- iso_date_string(&result->timestamp), type_string, result->data);
+}
Before this patch, the prefix indicated the type of report:
RHTSupport:<DATA>
meant "we reported it to RHTSsupport". This is needed to be able to figure out what<DATA> means.
Now, you print event name instead. What will happen if reporting is hooked, for example, to "post-create" event? It will be:
post-create:<DATA>
Now it is impossible to figure out, was it reported to RHTSupport? Bugzilla? Sent by email?
actually it adds the event name not the even type:
report_Logger: TIME=2011-07-22-23:32:03 URL=file:///home/jmoskovc/abrt.log
report_Bugzilla: TIME=2011-07-29-10:35:32 URL=https://bugzilla.redhat.com/show_bug.cgi?id=714989
- we can probably remove the report_ but it's easier to look for the
matching event, if we have the whole name...
- oh, now I get it... I wanted the event name because 2 events can share
the same reporter i.e
EVENT=report_BugzillaFedora reporter-bugzilla EVENT=report_BugzillaMandriva reporter-bugzilla -c conffile.conf
the in reported_to would be:
bugzilla: URL=bugzilla.redhat.com bugzilla: URL=bugzilla.mandriva.com
and I wanted to show
BugzillaMandriva: url BugzillaFedora: url
but without the event name I only can show:
bugzilla: url bugzilla: different_url
so generally I wanted to be able to find a xml and screen_name for event responsible for the line in reported_to