On Tue, 2011-05-24 at 09:58 +0200, Nikola Pajkovsky wrote:
Denys Vlasenko <dvlasenk(a)redhat.com> writes:
> On Mon, 2011-05-23 at 15:04 +0200, Nikola Pajkovsky wrote:
>> Jiri Moskovcak <jmoskovc(a)redhat.com> writes:
>>
>> > On 05/22/2011 09:28 PM, Denys Vlasenko wrote:
>> >> On Fri, 2011-05-20 at 14:08 +0200, Jiri Moskovcak wrote:
>> >>> I pushed the proposed changes,
>> >>
>> >> add_basics_to_problem_data needs to g_list_free(list)
>> >> the list of keys. I am going to push a fix.
>> >>
>> >>> the only thing which has left to fix is
>> >>> getting the component name (problem_data.c: 129). I need to ask rpm
for
>> >>> it and there are few possible solution:
>> >>>
>> >>> 1. call abrt-action-save-package-data
>> >>> 2. $ rpm -qf executable
>> >>> 3. use librpm
>> >>>
>> >>> Suggestions?
>> >>
>> >> I propose to add abrt-action-save-package-data call to reporters.
>> >>
>> >
>> > - ok, Nikola is working on adding this to bz plugin
>>
>> Yep, working on it. Denys, Jiri, do you want to simple call
>> SavePackageDescriptionToDebugDump or split that giant function into
>> a small separate functions and be able call those small functions? Do you
>> want to store it into dump dir?
>
> I think it woulr be cleaner if abrt-action-bugzilla knows nothing about
> packages and rpm db.
>
> How about this patch? -
+ test -f component || abrt-action-save-package-data
I like your idea, but _abrt-action-save-package-data_ doesn't save only
component, but even _package_. If missing even _package_ name we should
at least try to run abrt-action-save-package-data also.
Add line?
+ test -f package || abrt-action-save-package-data
Depends on what do you mean. If you want to say "run
abrt-action-save-package-data if either component or package is
missing", then:
test -f component -a -f package || abrt-action-save-package-data
--
vda