[Crash-utility] add print raw data capability for rd

Lei Wen adrian.wenl at gmail.com
Tue Oct 4 14:54:36 UTC 2011


Hi Dave,

On Tue, Oct 4, 2011 at 10:42 PM, Dave Anderson <anderson at redhat.com> wrote:
>
>
> ----- Original Message -----
>>
>> Thanks for detailed explaination. :)
>> I made another patch to address the mentioned issues.
>>
>> Thanks,
>> Lei
>
> OK Lei, I've attached what I have queued for crash-5.1.9.
> I made these changes to your last patch:
>
> - Reworded the "help rd" output.
>
> - Created an exported set_tmpfile2() function that allows
>  the caller to pass in their own FILE pointer of an open file
>  that only exists during the execution of a command.  It will
>  afford the recursive-use protection of open_tmpfile2() plus
>  the automatic closure of the file if the command fails prior
>  to completion or if the user forgets to close it with
>  close_tmpfile2().
>
> - Call close_tmpfile2() display_memory() after the copy is complete.
>
> - Passed the filename in an additional "opt" parameter to display_memory(),
>  which can be used in the future for any new features that come along.
>
> - Enforced the use of either a "count" argument or the use of
>  "-e ending-addr", since a default copy of 1 byte doesn't make
>  much sense.
>
> - Made the output loop use an fwrite() of the whole buffer instead
>  of fputc() of each byte.
>
> Thanks,
>  Dave
>

Your change sounds great to me. Nice to see this function finally goes
to release. :)

Thanks,
Lei




More information about the Crash-utility mailing list