simplify.c (gfc_simplify_transfer): Zero-initialize the buffer.
* simplify.c (gfc_simplify_transfer): Zero-initialize the buffer. From-SVN: r144663
This commit is contained in:
parent
8ae5dff133
commit
47ed69db7e
@ -1,3 +1,8 @@
|
||||
2009-03-06 Alexandre Oliva <aoliva@redhat.com>
|
||||
|
||||
* simplify.c (gfc_simplify_transfer): Zero-initialize the
|
||||
buffer.
|
||||
|
||||
2009-02-27 Tobias Burnus <burnus@net-b.de>
|
||||
|
||||
PR fortran/39309
|
||||
|
@ -4541,6 +4541,7 @@ gfc_simplify_transfer (gfc_expr *source, gfc_expr *mold, gfc_expr *size)
|
||||
/* Allocate the buffer to store the binary version of the source. */
|
||||
buffer_size = MAX (source_size, result_size);
|
||||
buffer = (unsigned char*)alloca (buffer_size);
|
||||
memset (buffer, 0, buffer_size);
|
||||
|
||||
/* Now write source to the buffer. */
|
||||
gfc_target_encode_expr (source, buffer, buffer_size);
|
||||
|
Loading…
x
Reference in New Issue
Block a user