re PR libfortran/45165 (unix.c:fallback_access() leaks file descriptors)
[gcc.git] / libgfortran / ChangeLog
1 2011-02-26 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
2
3 PR libfortran/45165
4 * unix.c (fallback_access): Fix file descriptor leaks.
5
6 2011-02-25 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
7
8 * acinclude.m4 (LIBGFOR_CHECK_FPSETMASK): Set shell variable
9 tested in configure.host.
10 * configure: Regenerate.
11
12 2011-02-24 Janne Blomqvist <jb@gcc.gnu.org>
13
14 PR libfortran/47802
15 * config.h.in: Regenerated.
16 * configure: Regenerated.
17 * configure.ac: Remove checks for ctime and ctime_r, add check for
18 strftime.
19 * intrinsics/date_and_time.c (localtime_r): Move fallback
20 implementation to time_1.h.
21 * intrinsics/time_1.h (localtime_r): Fallback implementation.
22 * intrinsics/ctime.c: Include time_1.h.
23 (ctime_r): Remove fallback implementation.
24 (strctime): New function.
25 (fdate): Use strctime instead of ctime_r.
26 (fdate_sub): Likewise.
27 (ctime): Likewise.
28 (ctime_sub): Likewise.
29
30 2011-02-24 Jakub Jelinek <jakub@redhat.com>
31
32 PR fortran/47878
33 * io/transfer.c (read_sf): Call fbuf_getptr only at the end,
34 and subtract n, dtp->u.p.sf_seen_eor and seen_comma from it.
35
36 2011-02-24 Janne Blomqvist <jb@gcc.gnu.org>
37
38 PR libfortran/47802
39 * configure.ac: Add test for POSIX getpwuid_r.
40 * intrinsics/getlog.c (getlog): CPP test for
41 HAVE_POSIX_GETPWUID_R.
42 * config.h.in: Regenerated.
43 * configure: Regenerated.
44
45 2011-02-23 Jerry DeLisle <jvdelisle@gcc.gnu.org>
46
47 PR libgfortran/47567
48 * io/write_float.def (output_float): Remove special case handling of
49 zero with width 1.
50
51 2011-02-23 Janne Blomqvist <jb@gcc.gnu.org>
52 Jerry DeLisle <jvdelisle@gcc.gnu.org>
53
54 PR libfortran/47694
55 * io/fbuf.h (fbuf_getptr): New inline function.
56 * io/transfer.c (read_sf): Use fbuf_getptr and fbuf_getc to scan
57 through the string instead of fbuf_read.
58
59 2011-02-22 Tobias Burnus <burnus@net-b.de>
60 Kai-Uwe Eckhardt <kuehro@gmx.de>
61
62 PR libfortran/47830
63 * intrinsics/c99_functions.c (roundl): Make C valid for
64 HAVE_NEXTAFTERL.
65
66 2011-02-19 Jerry DeLisle <jvdelisle@gcc.gnu.org>
67
68 PR libgfortran/47567
69 * io/write_float.def (output_float): Adjust width for F0.d to
70 allow space for negative signs on zero.
71
72 2011-02-16 Jerry DeLisle <jvdelisle@gcc.gnu.org>
73
74 PR libgfortran/47667
75 * io/list_read.c (read_logical): Check for end of line before calling
76 eat_line. (read_integer): Likewise. (parse_real): Don't unget the
77 separator. Check for end of line before calling eat_line.
78 (read_complex): Allow line-end before and after parenthesis and comma.
79 Check for end of line before calling eat_line. (read_real): Check for
80 end of line before calling eat_line.
81
82 2011-02-16 Jakub Jelinek <jakub@redhat.com>
83
84 PR libfortran/47757
85 * gfortran.map (GFORTRAN_1.4): Export
86 _gfortran_{m,s}i{all,any,parity}_i{1,2,4,8,16} and
87 _gfortran_{cshift0,eoshift{0,2}}_16_char4.
88
89 2011-02-15 Tobias Burnus <burnus@net-b.de>
90
91 PR fortran/47716
92 PR fortran/47648
93 * acinclude.m4 (LIBGFOR_CHECK_FLOAT128): Use check from
94 libquadmath, which uses more features.
95 * configure: Regenerate.
96
97 2011-02-14 Jakub Jelinek <jakub@redhat.com>
98
99 PR fortran/47642
100 * io/write_float.def (DTOAQ): Use quadmath_snprintf instead of
101 quadmath_flt128tostr.
102 * io/transfer128.c (tmp2): Initialize to quadmath_snprintf instead
103 of quadmath_flt128tostr.
104
105 2011-02-13 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
106
107 * Makefile.in: Regenerate.
108 * aclocal.m4: Likewise.
109 * configure: Likewise.
110
111 2011-02-05 Jerry DeLisle <jvdelisle@gcc.gnu.org>
112
113 PR libgfortran/47567
114 * io/write_float.def (output_float): Eliminate some redundant code.
115 Adjust width for case of F0.X for values of zero and all other values.
116 Expand cases where '*' is set to give cleaner results.
117
118 2011-02-05 Janne Blomqvist <jb@gcc.gnu.org>
119
120 PR libfortran/47571
121 * intrinsics/time_1.h (GF_CLOCK_MONOTONIC): Move to system_clock.c.
122 (weak_gettime): Likewise.
123 (gf_gettime): Change API, move weak_gettime() usage to
124 system_clock.c
125 * intrinsics/system_clock.c (GTHREAD_USE_WEAK): Define.
126 (gf_gettime_mono): New function.
127 (system_clock_4): Use gf_gettime_mono().
128 (system_clock_8): Likewise.
129 * intrinsics/date_and_time.c (date_and_time): Update gf_gettime()
130 usage.
131
132 2011-02-02 Janne Blomqvist <jb@gcc.gnu.org>
133
134 PR libfortran/47571
135 * configure: Regenerated.
136 * configure.ac: Don't add librt to LIBS.
137 * intrinsics/time_1.h (weak_gettime): Weakref trickery for
138 clock_gettime().
139 (gf_gettime): Use weak_gettime() instead of clock_gettime().
140
141 2011-02-01 Janne Blomqvist <jb@gcc.gnu.org>
142
143 * intrinsics/time_1.h: Include errno.h needed by fallbacks.
144
145 2011-01-31 Janne Blomqvist <jb@gcc.gnu.org>
146
147 * intrinsics/time_1.h: Fix definition of GF_CLOCK_MONOTONIC macro.
148
149 2011-01-31 Janne Blomqvist <jb@gcc.gnu.org>
150
151 * configure.ac: Check for clock_gettime().
152 * configure: Regenerated.
153 * config.h.in: Regenerated.
154 * intrinsics/time_1.h (__time_1): Rename to gf_cputime, add
155 times() fallback.
156 (gf_gettime): New function.
157 * intrinsics/cpu_time.c (__cpu_time_1): Update to call gf_cputime.
158 * intrinsics/date_and_time.c (date_and_time): Use gf_gettime.
159 * intrinsics/dtime.c (dtime_sub): Use gf_cputime.
160 * intrinsics/etime.c (etime_sub): Use gf_cputime.
161 * intrinsics/system_clock.c (system_clock_4): Use gf_gettime.
162 (system_clock_8): Use gf_gettime, increase count rate to allow
163 nanosecond precision, remove overflow prone branch.
164
165 2011-01-29 Jerry DeLisle <jvdelisle@gcc.gnu.org>
166
167 PR libgfortran/47434
168 * io/write_float.def (write_infnan): Use calculate_sign to determine
169 if the sign should be given and check field widths accordingly.
170
171 2011-01-29 Kai Tietz <kai.tietz@onevision.com>
172
173 * intrinsics/ctime.c (ctime_r): Improve implementation.
174
175 2011-01-27 Janne Blomqvist <jb@gcc.gnu.org>
176
177 PR libfortran/47431
178 * config.h.in: Regenerated.
179 * configure: Regenerated.
180 * configure.ac: Add check for ctime_r().
181 * intrinsics/ctime.c (ctime_r): Fallback implementation.
182 (fdate): Use ctime_r() instead of ctime().
183 (fdate_sub): Likewise.
184 (ctime): Likewise.
185 (ctime_sub): Likewise.
186
187 2011-01-27 Janne Blomqvist <jb@gcc.gnu.org>
188
189 PR libfortran/47432
190 * config.h.in: Regenerated.
191 * configure: Regenerated.
192 * configure.ac: Add check for ttyname_r.
193 * io/unix.h: Add TTY_NAME_MAX, change stream_ttyname prototype.
194 * io/unix.c (stream_ttyname): Use ttyname_r if available, conform
195 to new prototype.
196 * io/inquire.c (inquire_via_unit): Use changed stream_ttyname.
197 * io/intrinsics.c (ttynam_sub): Likewise.
198 (ttynam): Likewise.
199
200 2011-01-27 Janne Blomqvist <jb@gcc.gnu.org>
201
202 PR libfortran/47491
203 * configure.ac: Call AC_USE_SYSTEM_EXTENSIONS to enable common
204 extensions.
205 * config.h.in: Regenerate.
206 * configure: Regenerate.
207
208 2011-01-26 Jerry DeLisle <jvdelisle@gcc.gnu.org>
209
210 PR libgfortran/47285
211 * io/write_float.def (write_infnan): Adjust processor selected width
212 to 3 if NaN.
213
214 2011-01-26 Jerry DeLisle <jvdelisle@gcc.gnu.org>
215
216 PR libgfortran/47285
217 * io/write_float.def (output_float): Return SUCCESS or FAILURE and use
218 the result to set the padding.
219
220 2011-01-26 Kai Tietz <kai.tietz@onevision.com>
221
222 * intrinsics/getlog.c (getlog): Fix label/statement issue.
223
224 2011-01-25 Janne Blomqvist <jb@gcc.gnu.org>
225
226 PR libfortran/47375
227 * config.h.in: Regenerated.
228 * configure: Regenerated.
229 * configure.ac: Add check for getpwuid_r.
230 * intrinsics/getlog.c (getlog): Use getpwuid_r() if available.
231
232 2011-01-22 Janne Blomqvist <jb@gcc.gnu.org>
233
234 PR libfortran/46267
235 * config.h.in: Regenerated.
236 * configure: Regenerated.
237 * configure.ac: Check presence of strerror_r.
238 * intrinsics/gerror.c (gerror): Use gf_strerror, modify logic.
239 * io/unix.c (get_oserror): Remove.
240 * libgfortran.h (gf_strerror): Add prototype.
241 (get_oserror): Remove prototype.
242 * runtime/error.c (gf_strerror): New function.
243 (os_error): Use gf_strerror instead of get_oserror.
244 (generate_errror): Likewise.
245
246 2011-01-17 Janne Blomqvist <jb@gcc.gnu.org>
247
248 PR libfortran/47296
249 * io/unix.c (tempfile): Set opp->file and opp->file_len also if an
250 error occurs.
251
252 2011-01-16 Jakub Jelinek <jakub@redhat.com>
253
254 PR fortran/46625
255 * io/write_float.def (DTOAQ): Use quadmath_flt128tostr
256 instead of quadmath_dtoa.
257 * io/transfer128.c (tmp1, tmp2): New variables, bring in
258 strtoflt128 and quadmath_flt128tostr.
259 (transfer_real128, transfer_real128_write, transfer_complex128,
260 transfer_complex128_write): Remove tmp1/tmp2 variables.
261 * io/read.c (convert_real): Use strtoflt128 instead of
262 quadmath_strtopQ, adjust for the changed arguments and return
263 value.
264
265 2011-01-14 Jerry DeLisle <jvdelisle@gcc.gnu.org>
266
267 PR libgfortran/47296
268 * io/unix.c (unpack_filename): Return non-zero if the filename passed
269 in is NULL.
270
271 2011-01-04 Jerry DeLisle <jvdelisle@gcc.gnu.org>
272
273 PR libgfortran/47154
274 * io/list_read.c (namelist_read): Remove calls to hit_eof to avoid the
275 duplicate calls via next_record.
276
277 \f
278 Copyright (C) 2011 Free Software Foundation, Inc.
279
280 Copying and distribution of this file, with or without modification,
281 are permitted in any medium without royalty provided the copyright
282 notice and this notice are preserved.