From f2cc43b93920a7e32c5c31f4ca5171691226ee71 Mon Sep 17 00:00:00 2001 From: Denys Vlasenko Date: Thu, 10 Feb 2011 15:35:06 +0100 Subject: updated doc/TODO_crash_dump_fields Signed-off-by: Denys Vlasenko --- doc/TODO_crash_dump_fields | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/doc/TODO_crash_dump_fields b/doc/TODO_crash_dump_fields index 7a8407fb..a35b3b04 100644 --- a/doc/TODO_crash_dump_fields +++ b/doc/TODO_crash_dump_fields @@ -47,3 +47,21 @@ printable_form_of_crash_item(...) dd_load_text_ext(dd, "time", flags) may benefit from a new flag DD_LOAD_TEXT_PRINTABLE, which makes it generate printable representation of fields. + + + Reduce amount of special-casing in the code which works with crash_data + +Examples: + +Reporters use something like this to exclude "non-interesting" fields: + +for (each crash_data element) +{ + if (strcmp(short_name, FILENAME_COUNT) == 0) goto next; + if (strcmp(short_name, CD_DUMPDIR) == 0) goto next; + if (strcmp(short_name, FILENAME_INFORMALL) == 0) goto next; + if (strcmp(short_name, FILENAME_MESSAGE) == 0) goto next; // plugin's status message (if we already reported it yesterday) + ... +} + +Can it be done with a flag? -- cgit