This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[PATCH, MELT] correct meltgc_string_hex_md5sum_file_sequence


Hello

Here is a patch allowing to compute correctly the md5 of a file sequence
even with the bug rapported here:
http://gcc.gnu.org/ml/gcc-patches/2011-09/msg00963.html.

The function will work with both gcc 4.6 without the patch and a gcc
with the patch applied.

The problem cames from the fact that we were calling md5_process_bytes
several times with a buffer of a size which was not a multiple of 64.
Doing so, the next buffer was modified to take those data in account and
doing so, we had not always an aligned pointer.

We now concatenate file stream and so we can have a buffer with a
multiple of 64 size, so we can call md5_process_block. We only call
md5_process_bytes for the last data.

Thanks!

Pierre Vittet

Attachment: meltgc_string_hex_md5sum_file_sequence-4.6compatible-178881.ChangeLog
Description: Text document

Attachment: meltgc_string_hex_md5sum_file_sequence-4.6compatible-178881.diff
Description: Text document


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]