[Crash-utility] Patch to fix Seg Violation in parse_for_member

Bob Montgomery bob.montgomery at hp.com
Thu Aug 9 22:31:09 UTC 2012


On Thu, 2012-08-09 at 16:23 -0600, Bob Montgomery wrote:
> If you change the 
>      fprintf(pc->saved_fp, buf);
> lines to 
>      print_verbatim(pc->saved_fp, buf);
> 
> Then I won't get:
> 
> crash> sk_buff.head ffff88012014dc80
> Segmentation fault
> 
> When I need to get:
> 
> crash> sk_buff.head ffff88012014dc80
>   head = 0xffff880121267000 "\"%s %s %s\", got type \"%s\""
> 
> 
> Patch attached (6.0.8).
> 
> I suspect performance will suffer a bit when I try to print
> 2 million of these...

Wonder if it would be quicker on average to string search for "%" and
conditionally call print_verbatim???  I had lots of successful 
fprintf's and only a small number of seg viol cases.

Bob M.





More information about the Crash-utility mailing list