From c42a19d5e3a8236af3b727cd708bac22a8608b9d Mon Sep 17 00:00:00 2001 From: Thomas Koenig Date: Thu, 12 May 2005 17:50:33 +0000 Subject: re PR libfortran/21324 (#undef GFC_CLEAR_MEMORY causes testsuite failures) 2005-05-12 Thomas Koenig PR libfortran/21324 * runtime/memory.c: Don't define GFC_CLEAR_MEMORY (it's a performance hog). * io/open.c (new_unit): Zero freshly allocated memory for unit structure. * io/unit.c (init_units): Zero freshly allocated memory for STDIN, STDOUT and STDERR. * io/unix.c (open_internal): Zero freshly allocated memory for unix_stream. (fd_to_stream): Likewise. From-SVN: r99619 --- libgfortran/io/open.c | 1 + 1 file changed, 1 insertion(+) (limited to 'libgfortran/io/open.c') diff --git a/libgfortran/io/open.c b/libgfortran/io/open.c index 97bf6e4..f579f1f 100644 --- a/libgfortran/io/open.c +++ b/libgfortran/io/open.c @@ -351,6 +351,7 @@ new_unit (unit_flags * flags) /* Create the unit structure. */ u = get_mem (sizeof (gfc_unit) + ioparm.file_len); + memset (u, '\0', sizeof (gfc_unit) + ioparm.file_len); u->unit_number = ioparm.unit; u->s = s; -- cgit v1.1