1 2001-05-24 Jim Meyering <meyering@lucent.com>
3 * argmatch.c: Include "quote.h".
4 (argmatch_invalid): Remove explicit `' quotes. Instead, use the
5 quote function. Reported by Göran Uddeborg.
7 2001-05-20 Alexandre Duret-Lutz <duret_g@epita.fr>
9 * dirname.c (dir_name): Compute append_dot using path, not newpath
10 which is not yet declared.
12 2001-05-11 Paul Eggert <eggert@twinsun.com>
14 * lib/Makefile.am (libfetish_a_SOURCES):
15 Add strftime.c, since we now compile it on all hosts.
17 * lib/strftime.c (my_strftime):
18 Define to nstrftime if emacs, but only if my_strftime is not defined.
19 (extra_args, extra_args_spec, extra_args_spec_iso): Rename from
20 ut_argument, ut_argument_spec, ut_argument_spec_iso, respectively.
21 Add one more extra argument: a nanoseconds value.
24 (my_strftime function): Add %N format.
25 (emacs_strftimeu): Renamed from emacs_strftime,
26 with extra ut argument.
28 2001-05-11 Paul Eggert <eggert@twinsun.com>
30 dirname code cleanup. base_name now behaves more compatibly
31 with POSIX basename when given file names that have trailing
32 slashes, and similarly for dir_name. Add new primitives
33 base_len and dir_len. Put the directory-name-related decls
36 * addext.c (ISSLASH, base_name): Remove; now in dirname.h.
37 * backupfile.c (base_name): Likewise.
38 * basename.c (FILESYSTEM_PREFIX_LEN, PARAMS, ISSLASH): Likewise.
39 * dirname.c (FILESYSTEM_PREFIX_LEN, ISSLASH): Likewise.
40 * makepath.c (strip_trailing_slashes): Likewise.
41 * path-concat.c (DIRECTORY_SEPARATOR, FILESYSTEM_PREFIX_LEN, ISSLASH):
43 * rename.c (strip_trailing_slashes): Likewise.
44 * same.c (base_name): Likewise.
45 * stripslash.c (ISSLASH): Likewise.
47 * addext.c: Include <dirname.h> after size_t is defined.
48 * backupfile.c: Likewise.
50 * addext.c (addext): Use base_len to trim redundant
51 trailing slashes instead of doing it ourselves.
52 But do not trim the last slash if it is not redundant.
54 * backupfile.c (find_backup_file_name,
55 max_backup_version): Use base_len instead of rolling it ourselves.
56 Handle the case of "" and (on DOS) "C:" correctly.
58 * basename.c: Do not include <stdio.h>, <assert.h>; no longer needed.
59 Include <string.h>, <dirname.h>.
60 (base_name): Allow file names ending in slashes, other than names
61 that are all slashes. In this case, return the basename followed
62 by the slashes. This is more general, and can be used in places
63 where the original base_name purposely had an assertion failure.
64 (base_len): New function.
66 * dirname.c: Include <string.h> instead of <stdlib.h>.
67 Do not include <assert.h>; no longer needed.
69 (memrchr): Remove decl.
71 (dir_len): Renamed from dirlen. All callers changed.
72 Rewrite in terms of base_name, for simplicity and consistency.
73 (dir_name): Never return NULL. All callers changed.
74 Do not include <stdlib.h> in test program; no longer needed.
75 return 0; is fine for test program.
77 * dirname.h (DIRECTORY_SEPARATOR, ISSLASH, FILESYSTEM_PREFIX_LEN):
79 (base_name, base_len, dir_len, strip_trailing_slashes): New decls.
81 * path-concat.c (path_concat): Use base_len to compute
82 base length, not strlen; this means we cannot rely on memcpy
85 * same.c (STREQ): Remove.
86 (same_name): Handle the case where the basename ends in trailing '/'.
88 * stripslash.c (strip_trailing_slashes): Return nonzero if
89 a slash was stripped. Do not strip the last slash after a
92 2001-04-08 Jim Meyering <meyering@lucent.com>
94 * getdate.y (get_date): Set tm_isdst to -1 to ensure that it is
95 recomputed; that's necessary when the offset spans a DST transition.
96 Patch by David J. MacKenzie. Reported by Hon-Yin Kok.
98 2001-04-02 Jim Meyering <meyering@lucent.com>
100 * regex.h, regex.c: Update from GNU libc.
102 2001-03-19 Paul Eggert <eggert@twinsun.com>
104 * version-etc.c (version_etc_copyright): Update to 2001.
106 2001-03-16 Paul Eggert <eggert@twinsun.com>
108 * tempname.c (uint64_t): Define to uintmax_t if
109 not defined, and if UINT64_MAX is not defined.
110 Required at least for Vax Ultrix4.3, which doesn't define uint64_t.
111 Reported by John David Anglin.
113 2001-03-10 Bruno Haible <haible@clisp.cons.org>
115 * localcharset.c (locale_charset): Allow wildcard syntax. Also resolve
116 alias if codeset is empty.
117 * config.charset (BeOS): Use wildcard syntax.
119 2001-03-13 Jim Meyering <meyering@lucent.com>
121 * path-concat.c (path_concat) [FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]:
122 Don't insert a backslash when concatenating e.g., `C:' and `foo'.
125 2001-03-06 Bruno Haible <haible@clisp.cons.org>
127 * localcharset.c (locale_charset): Don't use setlocale(LC_CTYPE,NULL).
129 * unicodeio.c (print_unicode_char): Simplify accordingly.
131 2001-03-06 Bruno Haible <haible@clisp.cons.org>
133 * config.charset: Update for FreeBSD 4.2 and OSF/1 5.1. Add
134 support for DOS/DJGPP.
136 2001-02-28 Paul Eggert <eggert@twinsun.com>
138 * Makefile.am (libfetish_a_SOURCES):
139 Add dup-safer.c, fopen-safer.c.
140 (noinst_HEADERS): Add stdio-safer.h, unistd-safer.h.
142 * dup-safer.c, fopen-safer.c, stdio-safer.h,
143 lib/unistd-safer.h: New files.
145 2001-02-25 Paul Eggert <eggert@twinsun.com>
147 The mkstemp replacement is taken from glibc 2.2.2, with some
148 portability fixes for use outside glibc, as follows:
150 * tempname.c (struct_stat64): New macro.
151 (direxists, __gen_tempname): Use it.
152 This avoids a portability problem with Solaris 8.
154 * tempname.c (<config.h>): Include if HAVE_CONFIG_H.
155 (<stddef.h>, <stdint.h>, <string.h>):
156 Include only if STDC_HEADERS || _LIBC.
157 (<fcntl.h>): Include only if HAVE_FCNTL_H || _LIBC.
158 (<unistd.h>): Include only if HAVE_UNISTD_H || _LIBC.
159 (<sys/time.h>): Include only if HAVE_SYS_TIME_H || _LIBC.
160 (__set_errno): Define this macro if <errno.h> doesn't.
161 (P_tmpdir, TMP_MAX, __GT_FILE, __GT_BIGFILE, __GT_DIR, __GT_NOCREATE):
162 Define these macros if <stdio.h> doesn't.
163 (S_ISDIR, S_IRUSR, S_IWUSR, S_IXUSR):
164 Define these macros if <sys/stat.h>
165 doesn't. Ignore <sys/stat.h> S_ISDIR if STAT_MACROS_BROKEN.
166 (stat64, __getpid, __gettimeofday, __mkdir, __open, __open64, lxstat64,
167 __xstat64): Define if not _LIBC.
168 (__secure_getenv): Define if ! (HAVE___SECURE_GETENV || _LIBC).
169 (__gen_tempname): Invoke gettimeofday only if
170 HAVE_GETTIMEOFDAY || _LIBC;
171 otherwise, fall back on plain "time".
172 Use macros like S_IRUSR | S_IWUSR rather than octal values like 0600.
174 * mkstemp.c (__GT_FILE): Define to zero if not defined.
176 * mkstemp.c, tempname.c: New files, taken from glibc 2.2.2.
178 2001-02-17 Jim Meyering <meyering@lucent.com>
180 * strtoul.c: Sync from GNU libc. Use double quotes, not <...>
181 around included file name.
183 * strnlen.c (__strnlen): Merge in a change from GNU libc.
185 * strftime.c: Update from GNU libc (the only changes were to comments).
187 2001-02-13 Bruno Haible <haible@clisp.cons.org>
189 * mbswidth.h (mbswidth): Also define as macro, to avoid prototype clash.
191 2001-02-17 Paul Eggert <eggert@twinsun.com>
193 * mbswidth.c, quotearg.c (mbrtowc, mbsinit):
194 Remove workaround macros for hosts that have mbrtowc but not
195 mbstate_t, as we now insist on proper declarations for both
196 before using mbrtowc.
198 2001-02-17 Jim Meyering <meyering@lucent.com>
200 * regex.c: Update from libc.
202 2001-02-16 Paul Eggert <eggert@twinsun.com>
204 * alloca.c (malloc): Undef before defining, since stdlib.h
205 may have defined it. Needed for Encore Umax-3.0.9.16b systems.
206 Reported by Mark Hounschell via Paul Eggert.
208 2001-01-30 Bruno Haible <haible@clisp.cons.org>
210 * config.charset: Update for FreeBSD 4.2.
212 2001-01-26 Jim Meyering <meyering@lucent.com>
214 * quotearg.c: Include stddef.h.
215 * quote.c: Include stddef.h.
216 Reported by Axel Kittenberger.
218 * xmalloc.c [HAVE_DONE_WORKING_MALLOC_CHECK]: Enclose error-evoking
219 line in double quotes so that it evokes a better diagnostic.
220 [HAVE_DONE_WORKING_REALLOC_CHECK]: Likewise.
221 Reported by Axel Kittenberger.
223 2001-01-15 Bruno Haible <haible@clisp.cons.org>
225 * unicodeio.c (print_unicode_char): Cast the second iconv() arg,
226 to avoid a warning. Add back 'const' to inptr.
228 2001-01-16 Jim Meyering <meyering@lucent.com>
230 * basename.c: Include <stdio.h>, needed by assert on SunOS4.
233 2001-01-14 Jim Meyering <meyering@lucent.com>
235 * rename.c: New file. From Volker Borchert.
236 Include stdlib.h, string.h or strings.h, and xalloc.h.
237 Use strip_trailing_slashes rather than open-coding it.
239 2001-01-03 Paul Eggert <eggert@twinsun.com>
241 * strftime.c: Sync with glibc time/strftime.c 1.81.
243 2001-01-03 Jim Meyering <meyering@lucent.com>
245 * unicodeio.c (print_unicode_char): Remove `const' from declaration of
246 local `inptr' to avoid warning with some system declarations of iconv.
248 2000-12-29 Paul Eggert <eggert@twinsun.com>
250 * modechange.c: Do not assume that mode_t uses the
251 traditional octal encoding. E.g. "chmod 1 FOO" should set
252 the other-execute bit of FOO even if S_IXOTH != 1.
254 (SUID, SGID, SVTX, RUSR, WUSR, XUSR, RGRP, WGRP, XGRP, ROTH,
255 WOTH, XOTH, ALLM): New macros.
256 (S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR,
257 S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH):
259 (S_ISGID): Fix typo; it was defaulting to the same value as S_ISUID.
260 (S_IRWXU, S_IRWXG, S_IRWXO): Specify defaults in terms of the above.
262 No need to use uintmax_t; unsigned long is long enough.
263 Don't bother to get suffix since we don't use it.
265 2000-12-24 Jim Meyering <meyering@lucent.com>
267 * hash.c (is_prime): Return explicit boolean values.
268 (hash_get_first): Return NULL to appease Irix5.6's 89.
269 Reported by Nelson Beebe.
271 2000-10-31 Bruno Haible <haible@clisp.cons.org>
273 * localcharset.c (locale_charset): Add support for Win32.
275 2000-12-18 Paul Eggert <eggert@twinsun.com>
277 * physmem.h, physmem.c: New files.
279 * Makefile.am (libfetish_a_SOURCES): Add physmem.c.
280 (noinst_HEADERS): Add physmem.h.
282 * xstrtol.c (__xstrtol): Add undocumented suffixes 'g' and
283 't' for compatibility with Solaris 8 sort.
285 2000-12-18 Bruno Haible <haible@clisp.cons.org>
287 * config.charset: Add support for BeOS.
289 2000-12-16 Jim Meyering <meyering@lucent.com>
291 * getusershell.c [!SHELLS_FILE && __DJGPP__]: Define
292 SHELLS_FILE to a file name that's useful on djgpp systems.
294 (ADDITIONAL_DEFAULT_SHELLS): Define.
295 (default_shells): Prepend ADDITIONAL_DEFAULT_SHELLS.
296 Based mostly on a patch from Prashant TR.
298 2000-12-16 Jim Meyering <meyering@lucent.com>
300 This bug had a serious impact on chown: `chown N:M FILE' (for integer
301 N and M) would have treated it like `chown N:N FILE'.
303 * userspec.c (parse_user_spec): Fix typo: s/u/g/.
305 2000-10-31 Bruno Haible <haible@clisp.cons.org>
307 * config.charset: Add ISO-8859-3, BIG5HKSCS, GB18030, JOHAB, VISCII,
308 CP874, CP949, CP950, CP1250, CP1253, CP1254, CP1255, CP1256, CP1257
309 to the list of canonical encodings. Rename EUC-CN to GB2312.
311 2000-12-08 Andreas Schwab <schwab@suse.de>
313 * mbswidth.c (mbsnwidth): Don't loop endlessly when called with an
314 invalid mulitbyte sequence and with the MBSW_ACCEPT_INVALID flag set.
316 2000-12-07 Jim Meyering <meyering@lucent.com>
318 * stripslash.c (ISSLASH): Define.
319 (strip_trailing_slashes): Use ISSLASH rather than comparing against `/'.
322 * dirname.c (FILESYSTEM_PREFIX_LEN): Define.
323 (dir_name_r): Declare this function as static.
324 [BACKSLASH_IS_PATH_SEPARATOR]: Fix a bug that'd
325 manifest itself on a name containing a mix of slashes and
327 Make this function work with names starting with a DOS-style
328 drive letter and colon prefix.
329 (dir_name): Append `.' if necessary.
330 Based mostly on patches from Prashant TR and Eli Zaretskii.
332 * dirname.h (dir_name_r): Remove prototype.
334 2000-12-05 Jim Meyering <meyering@lucent.com>
336 * dirname.c (dir_name_r): Add `const' in a few local declarations.
338 2000-12-04 Jim Meyering <meyering@lucent.com>
340 * path-concat.c: [!HAVE_DECL_MALLOC]: Declare malloc.
341 Also include memory.h, stdlib.h, unistd.h if appropriate.
342 Reported by Andreas Jaeger (conflicting declaration of malloc).
344 2000-12-02 Jim Meyering <meyering@lucent.com>
346 * closeout.h: Make idempotent, to avoid some obscure warnings.
348 2000-12-01 Paul Eggert <eggert@twinsun.com>
350 * memrchr.c: Include <config.h> before any system include file.
352 2000-11-29 Paul Eggert <eggert@twinsun.com>
354 * dirname.c (dir_name_r): Fix typo: int -> size_t.
356 2000-11-26 Jim Meyering <meyering@lucent.com>
358 * memcoll.c: Include sys/types.h. From Werner Almesberger.
360 2000-11-22 Paul Eggert <eggert@twinsun.com>
362 * strftime.c (my_strftime): Do not invoke mbrlen with a
363 size of (size_t) -1; it's not portable.
365 2000-11-17 Akim Demaille <akim@epita.fr>
367 * obstack.h: Formatting changes.
368 (obstack_grow, obstack_grow0): Don't cast WHERE at all: that would
369 prevent type checking.
370 (obstack_ptr_grow, obstack_ptr_grow_fast): When assigning, don't
371 cast the value to (void *): assigning a `foo *' to a `void *'
373 (obstack_int_grow, obstack_int_grow_fast): Don't cast AINT to int.
375 2000-11-17 Jim Meyering <meyering@lucent.com>
377 * strstr.c: Update from GNU libc.
379 2000-11-16 Jim Meyering <meyering@lucent.com>
381 * strverscmp.c: Incorporate weak-alias-related changes from glibc.
383 2000-11-11 Jim Meyering <meyering@lucent.com>
385 * error.c: Add a couple #includes, merging from GNU libc version.
387 2000-11-10 Jim Meyering <meyering@lucent.com>
389 * obstack.h: Update from GNU libc.
390 * obstack.c: Likewise.
392 2000-11-06 Paul Eggert <eggert@twinsun.com>
394 * getusershell.c (setusershell): Use rewind rather than
395 fseek/fseeko, to avoid configuration hassles with fseeko.
396 Don't bother opening SHELLS_FILE if shellstream is NULL;
399 2000-11-05 Jim Meyering <meyering@lucent.com>
401 * makepath.h (make_dir): Declare.
402 * makepath.c (make_dir): Remove `static' attribute.
405 2000-11-04 Alexandre Duret-Lutz <duret_g@epita.fr>
407 * hash.c (hash_get_next): Fix a thinko: when ENTRY is the
408 last one in a bucket, advance to the next bucket.
410 2000-11-02 Vesselin Atanasov <vesselin@bgnet.bg>
412 * fnmatch.c: Do not comment out all the code if we are using
413 the GNU C library, because in some cases we are replacing buggy
414 code in the GNU C library itself.
416 2000-10-30 Paul Eggert <eggert@twinsun.com>
418 * error.h, getline.h, modechange.h:
419 Remove "2000" from Copyright line, as the file hasn't been
420 changed this year other than in the copyright notice.
422 * xalloc.h: Add "2000" to Copyright line, as this file
423 was changed this year.
425 2000-10-30 Paul Eggert <eggert@twinsun.com>
427 * fnmatch.c (FOLD): Do not assume that characters are unsigned.
428 (fnmatch): Fix some FNM_FILE_NAME and FNM_LEADING_DIR bugs,
429 e.g. fnmatch("d*/*1", "d/s/1", FNM_FILE_NAME) incorrectly yielded zero.
431 2000-10-29 Greg Louis <glouis@dynamicro.on.ca>
433 * regex.h (__restrict_arr): Move definition out of #ifndef block.
434 Required because egcs-2.91.66 (aka 1.1.2) defines __restrict, but
435 doesn't define __restrict_arr.
437 2000-10-29 Jim Meyering <meyering@lucent.com>
439 * xstat.in: Fix grammar in comment.
441 2000-10-28 Jim Meyering <meyering@lucent.com>
443 * memchr.c: Update from libc.
444 Adjust for portability:
445 [HAVE_STDLIB_H]: Include stdlib.h.
446 [HAVE_BP_SYM_H || _LIBC]: Guard inclusion of bp-sym.h.
448 [!weak_alias]: Define __memchr to memchr.
450 * regex.c: Update from libc.
452 * getopt1.c: Likewise.
453 * memcmp.c: Likewise.
455 * getusershell.c (setusershell) [HAVE_FSEEKO]: Use fseeko.
456 Avoid using fseek, when possible -- it's broken by design.
457 Patch by Ulrich Drepper.
459 2000-10-26 Jim Meyering <meyering@lucent.com>
461 * strftime.c: Update from libc.
463 2000-10-25 Jim Meyering <meyering@lucent.com>
465 * obstack.c: Update from libc.
467 2000-10-23 Jim Meyering <meyering@lucent.com>
469 * hard-locale.c (hard_locale): Revert last change -- it was simply
470 wrong. That set_locale call must not have any side effects.
473 2000-10-22 Jim Meyering <meyering@lucent.com>
475 * md5.c (md5_process_block) [OP]: Use `rol', not CYCLIC.
476 [CYCLIC]: Remove now-unused definition.
478 * save-cwd.c (O_DIRECTORY): Define, if needed.
479 (save_cwd) [HAVE_FCHDIR]: Use O_DIRECTORY when opening ".".
480 Suggestion from Ulrich Drepper.
482 2000-10-21 Jim Meyering <meyering@lucent.com>
484 * dirname.c (dir_name_r): New function, factored out of dir_name.
485 (dir_name): Use dir_name_r.
486 * dirname.h (dir_name_r): Declare it.
488 2000-10-21 Jim Meyering <meyering@lucent.com>
490 * dirname.c (memrchr): Declare if necessary.
491 (dir_name): Remove the restriction that there be no
492 trailing slashes. Now, this code skips past them, effectively
494 [TEST_DIRNAME] (main): New unit tests.
496 * memrchr.c: New file from GNU libc.
497 Undef __memrchr, too.
498 [!weak_alias]: Define __memrchr to memrchr.
499 Guard weak_alias use with `#ifdef weak_alias'.
501 2000-10-17 Jim Meyering <meyering@lucent.com>
503 * quote.h (PARAMS): Define and use.
504 Reported by Akim Demaille.
506 * getopt.c: Update from libc.
508 2000-10-16 Jim Meyering <meyering@lucent.com>
510 * hard-locale.c (hard_locale): Use "", not 0 as 2nd arg to setlocale.
513 2000-09-25 Jim Meyering <meyering@lucent.com>
515 * md5.h (rol): Define (from GnuPG).
517 * sha.c: Give credit (GnuPG) where due.
518 (M): Use rol rather than open-coding it.
521 2000-09-21 Jim Meyering <meyering@lucent.com>
523 * userspec.c (parse_user_spec): Remove debugging printf I'd added.
524 Reported by Michael Stone.
526 2000-09-20 Jim Meyering <meyering@lucent.com>
528 * Makefile.am (libfetish_a_SOURCES): Add sha.c.
529 (noinst_HEADERS): Add sha.h.
530 Based on code from Scott G. Miller and from GnuPG.
532 2000-09-15 Jim Meyering <meyering@lucent.com>
534 * regex.c: Update from libc.
536 2000-09-10 Jim Meyering <meyering@lucent.com>
538 * getopt.c (_getopt_internal): Update from glibc.
540 2000-09-09 Jim Meyering <meyering@lucent.com>
542 * quotearg.c: Rename ISASCII to IN_CTYPE_DOMAIN, so people don't
543 think it should be used as a general replacement for isascii.
544 * fnmatch.c: Likewise.
545 * mbswidth.c: Likewise
549 * userspec.c: Include sys/param.h and limits.h.
551 (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
552 (UID_T_MAX, GID_T_MAX, MAXUID, MAXGID): Define.
553 (parse_user_spec): Use xstrtoul, not atoi when converting numeric
554 UID, GID. Check range.
556 2000-09-06 Jim Meyering <meyering@lucent.com>
558 * getopt.c (_getopt_internal): Update from glibc.
560 2000-08-30 Jim Meyering <meyering@lucent.com>
562 * strftime.c: Merge in changes from GNU libc.
564 2000-08-26 Jim Meyering <meyering@lucent.com>
566 * closeout.c: Include "__fpending.h".
567 (close_stdout_status): Return right away if there's nothing to flush.
569 * Makefile.am (noinst_HEADERS): Add __fpending.h.
570 * __fpending.c: New file.
571 * __fpending.h: New file.
573 2000-08-07 Paul Eggert <eggert@twinsun.com>
575 Standardize on "memory exhausted" instead of "Memory exhausted"
576 or "virtual memory exhausted".
577 * obstack.c (print_and_abort): Use "memory exhausted", not
578 "virtual memory exhausted".
579 * same.c (same_name): Invoke xalloc_die instead of printing
581 * userspec.c (parse_user_spec): Likewise.
582 * bumpalloc.h: comment fix
583 * same.c, userspec.c: Include xalloc.h.
585 * xalloc.h (xalloc_msg_memory_exhausted): Now char const[],
586 not char *const and pointing to a constant array.
587 * xmalloc.c (xalloc_msg_memory_exhausted): Likewise.
588 (xrealloc): Comment fix.
590 * userspec.c (parse_user_spec):
591 Don't translate a message until just before returning,
592 to avoid unnecessary translation.
594 2000-08-07 Jim Meyering <meyering@lucent.com>
596 * addext.c, argmatch.c, argmatch.h, backupfile.h, bumpalloc.h,
597 chown.c, diacrit.h, dirname.h, dup2.c, exclude.h, fileblocks.c,
598 fnmatch.c, fnmatch.h, fsusage.c, fsusage.h, getdate.h,
599 getgroups.c, gethostname.c, getopt.h, group-member.c,
600 hard-locale.c, hash.h, isdir.c, lchown.c, linebuffer.c,
601 linebuffer.h, long-options.h, malloc.c, md5.c, md5.h, memchr.c,
602 memcmp.c, memcoll.c, memset.c, mktime.c, modechange.h, obstack.h,
603 pathmax.h, realloc.c, rmdir.c, safe-read.c, save-cwd.c, stime.c,
604 stpcpy.c, strcasecmp.c, strcspn.c, strdup.c, stripslash.c,
605 strstr.c, strtod.c, strtol.c, strtoul.c, strtoull.c, strtoumax.c,
606 utime.c, version-etc.h, xalloc.h, xstrdup.c, xstrtoumax.c,
607 yesno.c: Back out Copyright date changes for each file with no change
608 this year. This eases coordination with other programs using the same
609 source code modules. From Paul Eggert.
611 2000-08-03 Greg McGary <greg@mcgary.org>
613 * regex.c (SET_HIGH_BOUND, MOVE_BUFFER_POINTER,
614 ELSE_EXTEND_BUFFER_HIGH_BOUND): New macros.
615 (EXTEND_BUFFER): Use them.
617 2000-08-01 Jim Meyering <meyering@lucent.com>
619 * dirname.c (ISSLASH): Define.
620 (BACKSLASH_IS_PATH_SEPARATOR): Define.
621 (dir_name) [BACKSLASH_IS_PATH_SEPARATOR]: Handle the case in which
622 both `\' and `/' may be use as path separators.
623 Based on a patch from Prashant TR.
625 2000-07-31 Paul Eggert <eggert@twinsun.com>
627 * quotearg.c (quotearg_n_options): Don't make the initial
628 slot vector a constant, since it might get modified.
630 2000-07-31 Jim Meyering <meyering@lucent.com>
632 * xmalloc.c: Use `virtual memory exhausted', not `Memory exhausted'.
633 * obstack.c (print_and_abort): Likewise.
635 2000-07-30 Paul Eggert <eggert@twinsun.com>
637 * quotearg.c (quotearg_n_options): Preallocate a slot 0
638 buffer, so that the caller can always quote one small
639 component of a "memory exhausted" message in slot 0.
640 From a suggestion by Jim Meyering.
642 2000-07-30 Jim Meyering <meyering@lucent.com>
644 * makepath.c (make_path): Quote the other instance, too.
646 * quotearg.c (N_STATIC_SLOTVECS): Define.
647 (STATIC_BUF_SIZE): Define.
648 (quotearg_n_options): Use only statically allocated storage when
649 N < N_STATIC_SLOTVECS and the length of the quoted result is smaller
650 than STATIC_BUF_SIZE.
652 2000-07-29 Jim Meyering <meyering@lucent.com>
654 * diacrit.c (diacrit_diac): Use __MSDOS__ in favor of MSDOS.
655 * dirname.c (dir_name): Likewise.
657 * basename.c (base_name): Use ISSLASH rather than comparing against `/'.
659 * dirname.c (dir_name) [MSDOS]: Declare `lim' to be const.
660 (dir_name): Assert that there are no trailing slashes.
662 2000-07-18 Bruno Haible <haible@clisp.cons.org>
664 * mbswidth.h (mbswidth): Add a flags argument.
665 (mbswidth): New declaration.
666 (MBSW_ACCEPT_INVALID, MBSW_ACCEPT_UNPRINTABLE): New macros.
667 * mbswidth.c (mbswidth): Add a flags argument.
668 (mbsnwidth): New function.
670 2000-07-24 Jim Meyering <meyering@lucent.com>
672 * mbswidth.c: Remove useless #else. From Bruno Haible.
674 2000-07-23 Paul Eggert <eggert@twinsun.com>
676 * mbswidth.c (_XOPEN_SOURCE):
677 Don't define; this causes problems on Solaris 7.
678 (wcwidth) [!HAVE_DECL_WCWIDTH]: Declare.
680 2000-07-23 Paul Eggert <eggert@twinsun.com>
683 Include <wchar.h> even if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX),
684 so that mbstate_t is always defined.
686 Do not inspect MB_LEN_MAX, since it's incorrectly defined to
687 be 1 in at least one GCC installation, and this configuration
688 error is likely to be common. Ignoring MB_LEN_MAX hurts
689 performance on hosts that have mbrtowc but have only unibyte
690 locales, but I assume these hosts are rare.
692 2000-07-23 Paul Eggert <eggert@twinsun.com>
694 * quotearg.c: Streamline by invoking multibyte code only if needed.
695 <wchar.h>: Include only if HAVE_MBRTOWC && 1 < MB_LEN_MAX.
696 (MB_CUR_MAX): Redefine to 1 if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX).
697 (quotearg_buffer_restyled): If a unibyte locale, don't bother to
698 invoke multibyte primitives.
700 2000-07-23 Jim Meyering <meyering@lucent.com>
702 * basename.c (base_name): Add an assertion.
704 2000-07-15 Bruno Haible <clisp.cons.org>
706 * quotearg.c: When the system forces us to redefine mbstate_t,
707 shadow its mbsinit function.
709 2000-07-16 Bruno Haible <haible@clisp.cons.org>
711 * mbswidth.h: New file.
712 * mbswidth.c: New file.
713 * Makefile.am (libfetish_a_SOURCES): Add mbswidth.c.
714 (noinst_HEADERS): Add mbswidth.h.
716 2000-07-17 Bruno Haible <haible@clisp.cons.org>
718 * config.charset: Add support for FreeBSD. Improve support for HP-UX
721 2000-07-15 Jim Meyering <meyering@lucent.com>
723 * makepath.c: Include quote.h.
724 (make_path): Convert "`%s'" in format strings to "%s", and wrap each
725 corresponding argument in a `quote (...)' call.
726 Give better diagnostics.
728 * Makefile.am (libfetish_a_SOURCES): Add quote.c.
729 (noinst_HEADERS): Add quote.h.
731 * quote.c (quote, quote_n): New file. Two functions taken verbatim
732 from tar's src/misc.c.
733 * quote.h: New file. Prototypes for same.
735 2000-07-10 Paul Eggert <eggert@twinsun.com>
737 From a suggestion by Bruno Haible.
738 * quotearg.c (mbrtowc): Do not use HAVE_WCHAR_H in the definition.
739 Use defined mbstate_t, not HAVE_MBSTATE_T_OBJECT,
740 to decide whether to define the BeOS workaround macro;
741 this adjusts to the change to AC_MBSTATE_T.
743 2000-07-13 Paul Eggert <eggert@twinsun.com>
745 * quotearg.h (enum quoting style): New enum clocale_quoting_style.
747 * quotearg.c (quoting_style_args, quoting_style_vals,
748 quotearg_buffer_restyled): Add support for
749 clocale_quoting_style. Undo previous change to
750 locale_quoting_style behavior, and undo the "{LEFT QUOTATION MARK}"
751 and "{RIGHT QUOTATION MARK}" msgids.
753 2000-07-05 Paul Eggert <eggert@twinsun.com>
755 The old behavior of quoting `like this' doesn't look good with
756 newer, ISO-style fonts. See:
757 http://www.cl.cam.ac.uk/~mgk25/ucs/quotes.html
759 Instead, quote "like this" by default. Let the translator
760 tailor the locale-specific quoting behavior by providing
761 translations for {LEFT QUOTATION MARK} and {RIGHT QUOTATION MARK}.
763 * quotearg.c (N_): New macro.
764 (gettext_default): New function.
765 (quotearg_buffer_restyled): Use
766 gettext_default ("{LEFT QUOTATION MARK}", "\"") for left quote, and
767 gettext_default ("{RIGHT QUOTATION MARK}", "\"") for right quote.
769 2000-07-09 Jim Meyering <meyering@lucent.com>
771 * Most files: Update copyright dates to include 2000.
773 2000-07-08 Jim Meyering <meyering@lucent.com>
775 * xgethostname.c (ENAMETOOLONG): Define to an unlikely value
777 (xgethostname): Remove now-unnecessary #ifdef.
778 Move declaration of `err' into loop where it's used.
780 2000-07-05 Bruno Haible <haible@clisp.cons.org>
782 * xgethostname.c (xgethostname): Protect against the SunOS5.5 bug
783 by allocating a larger buffer. Test the gethostname return value for
784 being >= 0, not == 0, for BeOS. Don't exhaust memory if gethostname
785 returns an error and ENAMETOOLONG isn't defined.
787 2000-07-05 Paul Eggert <eggert@twinsun.com>
788 and Bruno Haible <haible@clisp.cons.org>
790 * quotearg.c (mbrtowc): Declare returned type, since BeOS doesn't.
792 2000-07-05 Bruno Haible <haible@clisp.cons.org>
794 * quotearg.c (struct quoting_options): Simplify quote_these_too
797 2000-07-03 Jim Meyering <meyering@lucent.com>
799 * strndup.c: [!HAVE_DECL_STRNLEN]: Declare strnlen.
800 Reported by Bruno Haible.
802 2000-07-04 Jim Meyering <meyering@lucent.com>
804 * quotearg.c: Make inclusion of <wchar.h> independent of whether
805 HAVE_MBRTOWC is set. Required at least for irix-5.6, which
808 2000-07-03 Paul Eggert <eggert@twinsun.com>
809 and Bruno Haible <haible@clisp.cons.org>
811 * quotearg.c (mbrtowc):
812 Assign to *pwc, and return 1 only if result is nonzero.
813 (iswprint): Use ISPRINT when substituting our own mbrtowc.
815 2000-07-03 Jim Meyering <meyering@lucent.com>
817 * readutmp.h: [HAVE_UTMPX_H]: Include <utmp.h> if HAVE_UTMP_H.
818 This is necessary to get a definition of e.g., UTMP_FILE on HP-UX 10.20.
821 2000-07-02 Jim Meyering <meyering@lucent.com>
823 * quotearg.c (mbstate_t): Don't define here.
825 2000-07-02 Jim Meyering <meyering@lucent.com>
827 * nanosleep.c (SIGCONT): Define if not already defined.
829 2000-06-17 Bruno Haible <haible@clisp.cons.org>
831 * mountlist.c: Use MOUNTED_FS_STAT_DEV instead of MOUNTED_NEXT_DEV,
832 per change in ../m4/ls-mntd-fs.m4.
833 (read_filesystem_list): Ignore symbolic links.
835 2000-06-29 Jim Meyering <meyering@lucent.com>
837 * same.c: Include <string.h> or <strings.h>, as appropriate,
838 for declaration of strcmp.
840 * long-options.c: Include <stdlib.h>, for declaration of exit.
842 * mountlist.c (fsp_to_string) [HAVE_F_FSTYPENAME_IN_STATFS]:
843 Avoid warning by casting result to `char *' to remove `const'.
845 2000-06-17 Bruno Haible <haible@clisp.cons.org>
847 * Makefile.am (libfetish_a_SOURCES): Remove readutmp.c.
849 2000-06-26 Paul Eggert <eggert@twinsun.com>
851 savedir now sets errno on failure and invokes xmalloc to get memory.
852 Fix a couple of other minor bugs while we're at it.
854 * savedir.c (<unistd.h>): Do not include; there's no need.
855 (NAMLEN): Remove macro.
856 (malloc, realloc): Remove decls.
858 ("xalloc.h"): Include.
859 (NAME_SIZE_DEFAULT): New macro.
860 (savedir): Use xmalloc / xrealloc to allocate memory.
861 Use NAME_SIZE_DEFAULT if name_size is negative or overflows to zero.
862 Skip "" directory entries.
863 Use strlen to calculate directory entry length, since the old method
864 is rarely used these days and isn't worth supporting.
865 Don't use a pointer after freeing it.
866 Check for integer overflow when calculating allocation size.
867 Use memcpy to copy entries, instead of stpcpy.
868 Set errno properly when returning NULL.
869 Check for readdir error.
871 2000-06-26 Jim Meyering <meyering@lucent.com>
873 * posixtm.c [HAVE_STDLIB_H]: Include stdlib.h, for decl of abort.
875 2000-06-17 Bruno Haible <haible@clisp.cons.org>
877 * getusershell.c (xmalloc, xrealloc): Remove functions.
879 Don't include <stdlib.h>. Don't declare malloc, realloc.
881 2000-06-23 Bruno Haible <haible@clisp.cons.org>
883 * unicodeio.c (print_unicode_char): Work around ansi2knr deficiency.
885 2000-06-24 Jim Meyering <meyering@lucent.com>
887 * error.c [!HAVE_DECL_STRERROR_R]: Declare strerror_r.
889 2000-06-21 Jim Meyering <meyering@lucent.com>
891 * getpass.c: New file, from Bruno Haible. Required for BeOS.
893 2000-06-19 Paul Eggert <eggert@twinsun.com>
895 * quotearg.c: Include <wctype.h> after <wchar.h>, for Solaris 2.5.
896 (mbrtowc, mbstate_t): Define substitutes if
897 HAVE_MBRTOWC && HAVE_WCHAR_H && !HAVE_MBSTATE_T_OBJECT.
898 (iswprint): Define to 1 if !defined iswprint && !HAVE_ISWPRINT,
899 not if ! (HAVE_MBRTOWC && HAVE_WCHAR_H).
901 2000-06-17 Bruno Haible <haible@clisp.cons.org>
903 * xgetcwd.c (xgetcwd): If the required pathname length is smaller
904 than 1024, return a memory chunk of least possible size, instead
905 of size PATH_MAX + 2. In the loop, increment the size proportionally.
906 Use free/xmalloc instead of xrealloc to avoid copying for very long
909 2000-06-17 Bruno Haible <haible@clisp.cons.org>
911 * canon-host.c (canon_host): Use malloc and memcpy to copy an
912 address, not strdup. Include <stdlib.h> and don't declare free().
914 2000-06-17 Bruno Haible <haible@clisp.cons.org>
916 * path-concat.c (path_concat): Don't access dir[-1] if dir is
919 2000-06-21 Jim Meyering <meyering@lucent.com>
921 * Makefile.am (libfetish_a_SOURCES): Add getstr.c.
922 (noinst_HEADERS): Add getstr.h.
924 * getline.c (getstr): Move into a separate file.
925 * getstr.c (getstr): New file, extracted from getline.c, with
926 the following changes: new parameter, delim2; both delim[12]
927 parameters have type `int', not `char'. The latter would lose
928 with 8-bit delimiters.
929 * getstr.h: New file.
931 2000-06-19 Jim Meyering <meyering@lucent.com>
933 * getloadavg.c [HAVE_NLIST_H] (NLIST_STRUCT): Define.
935 2000-06-18 Jim Meyering <meyering@lucent.com>
937 * mkdir.c: Remove file, due mainly to copyright incompatibility.
938 Besides, these days every porting target provides a mkdir function.
940 * strnlen.c: Include memory.h, string.h, and/or strings.h as needed.
941 (this snippet comes from src/system.h).
943 2000-06-15 Paul Eggert <eggert@twinsun.com>
945 * human.c (adjust_value): New function.
946 (human_readable_inexact): Apply rounding style even when
947 printing approximate values.
949 2000-06-14 Paul Eggert <eggert@twinsun.com>
951 * human.c (human_readable_inexact): Allow an input block
952 size that is not a multiple of the output block size, and vice versa.
953 Reported by Piergiorgio Sartor.
955 2000-06-14 Paul Eggert <eggert@twinsun.com>
957 * getdate.y (get_date): Apply relative times after time
958 zone indicator, not before. Reported by Todd A. Jacobs.
960 2000-06-13 Jim Meyering <meyering@lucent.com>
962 * Makefile.am (all-local): Depend on lstat.c and stat.c.
964 * xstat.in [!HAVE_DECL_FREE]: Declare free in lstat.c.
966 2000-06-12 Paul Eggert <eggert@twinsun.com>
968 * xstat.in: Include <stdlib.h> in lstat, to declare "free".
970 2000-06-04 Paul Eggert <eggert@twinsun.com>
972 * strnlen.c: Include <config.h> if HAVE_CONFIG_H.
974 2000-06-04 Jim Meyering <meyering@lucent.com>
976 * getugroups.c (getugroups): Cast -1 to gid_t, for systems like
977 SunOS4.1.4 for which gid_t is an unsigned type.
979 2000-06-03 Jim Meyering <meyering@lucent.com>
981 * strnlen.c [!HAVE_DECL_MEMCHR]: Declare memchr.
983 2000-05-26 Bruno Haible <haible@clisp.cons.org>
985 * Makefile.am (install-exec-local): On systems with glibc-2.1 or
986 newer, don't install charset.alias.
987 * config.charset: Change the Linux/glibc rules so they become empty
988 on glibc-2.1 or newer.
990 2000-06-02 Jim Meyering <meyering@lucent.com>
992 * mountlist.c: Back out last change. Instead, do this...
993 * mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Set the me_dummy
994 member using the same `ignore'-testing code.
995 * mountlist.h (ME_DUMMY): Add `autofs' to the list of ignored
999 2000-05-29 Jim Meyering <meyering@lucent.com>
1001 * mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Ignore mounts
1002 with the `ignore' attribute. Based on a patch from Mark D. Roth.
1004 2000-05-22 Jim Meyering <meyering@lucent.com>
1006 * makepath.c: Remove old, now-unnecessary `#ifdef __MSDOS__' block.
1008 2000-05-18 Jim Meyering <meyering@lucent.com>
1010 * hash.c (hash_rehash): Fix a nasty bug: copy the free entry list
1011 back, too, since it may have been modified by allocate_entry.
1012 (hash_delete): Rewrite to use neither the assignment operator
1013 nor the comma operator in an if-expression.
1015 2000-05-15 Paul Eggert <eggert@twinsun.com>
1018 <sys/stat.h>, <sys/types.h>, <unistd.h>, (STDOUT_FILENO):
1019 Remove; no longer needed.
1020 "quotearg.h": Add include.
1021 (file_name): Do not bother to explicitly initialize to NULL; it's less
1022 efficient on some hosts.
1023 (close_stdout_status): Remove test as to whether stdout was already
1024 closed; it breaks for the case "echo x | sort >&-".
1025 Quote file name colons.
1026 Do not assume that _("write error") lacks format strings.
1028 2000-05-15 Jim Meyering <meyering@lucent.com>
1030 * version-etc.c (version_etc_copyright): Update the copyright string
1031 used in all --version output.
1033 2000-05-14 Jim Meyering <meyering@lucent.com>
1035 * closeout.c (close_stdout_set_file_name): New function.
1036 (close_stdout_status): Use new file-scoped global.
1037 Return right away if fstat says the stdout file descriptor is invalid.
1038 * closeout.h (close_stdout_set_file_name): Declare.
1040 2000-05-10 Jim Meyering <meyering@lucent.com>
1042 * closeout.c [default_exit_status]: New file-scoped variable.
1043 (close_stdout_set_status): New function.
1044 * closeout.h (close_stdout_set_status): Declare.
1046 2000-05-08 Jim Meyering <meyering@lucent.com>
1048 * long-options.c: Don't include closeout.h.
1049 (parse_long_options): Don't call close_stdout for --version.
1051 2000-05-06 Jim Meyering <meyering@lucent.com>
1053 * strnlen.c: Undefine __strnlen and strnlen.
1054 [!weak_alias]: Define __strnlen to strnlen.
1056 * atexit.c: New file, from libiberty.
1058 2000-05-06 Jim Meyering <meyering@lucent.com>
1060 * closeout.c (close_stdout_status): Also check for errors on the
1063 2000-05-05 Bruno Haible <haible@clisp.cons.org>
1065 * localcharset.c (get_charset_aliases): Use malloc, realloc and memcpy
1066 instead of xmalloc, xrealloc, path_concat.
1067 (locale_charset): Treat empty environment variables as absent.
1068 (DIRECTORY_SEPARATOR, ISSLASH): New macros.
1070 2000-05-04 Jim Meyering <meyering@lucent.com>
1072 * getopt.c: Update from glibc.
1073 * obstack.c: Likewise.
1074 * obstack.h: Likewise.
1075 * regex.c: Likewise. NB: K&R compiler support is dropped for this file
1077 * regex.h: Likewise.
1078 * strndup.c: Likewise.
1079 * strnlen.c: New file, from glibc.
1081 2000-05-01 Jim Meyering <meyering@lucent.com>
1083 * full-write.c (full_write): Remove `FIXME' part of comment.
1085 2000-04-29 Jim Meyering <meyering@lucent.com>
1087 * path-concat.c: Declare strdup only if it's not defined.
1088 * canon-host.c: Likewise.
1090 2000-04-28 Jim Meyering <meyering@lucent.com>
1092 * rpmatch.c [HAVE_LIMITS_H]: Include limits.h before regex.h to avoid
1093 redefinition warning on some systems (HPUX). Otherwise, regex.h is
1094 included first, then limits.h is included by locale.h by libintl.h.
1095 From John David Anglin.
1097 2000-04-25 Jim Meyering <meyering@lucent.com>
1099 * makepath.c (S_IRWXUGO): Define.
1100 (make_path): Always perform explicit chmod if MODE specifies any
1101 of the `special' permission bits. Prompted by a bug report against
1102 install from Mate Wierdl and Joost van Baal.
1104 2000-04-18 Jim Meyering <meyering@lucent.com>
1108 * getpagesize.h [!getpagesize && HAVE_OS_H && B_PAGE_SIZE]: Define
1109 getpagesize. For BeOS. Based on a patch from Bruno Haible.
1111 2000-04-17 Jim Meyering <meyering@lucent.com>
1113 * strftime.c (my_strftime) [strftime]: Declare strftime here, since
1114 the definition of it to rpl_strftime also defined-away the system's
1117 2000-04-15 Jim Meyering <meyering@lucent.com>
1119 Use `C' to denote so-called `contiguous' files, the same way
1121 * filemode.c (S_ISCTG) [!S_ISCTG && S_IFCTG]: Define.
1122 (ftypelet): Use S_ISCTG.
1123 From Michael Deutschmann.
1125 2000-04-14 Jim Meyering <meyering@lucent.com>
1127 * strftime.c (my_strftime) [#ifdef strftime]: Declare strftime.
1129 2000-04-08 Jim Meyering <meyering@lucent.com>
1131 * Makefile.am (charset.alias): Use t-$@, not $@-t so the DOS 8.3
1132 names don't conflict. Reported by Eli Zaretskii.
1134 2000-03-28 Bruno Haible <haible@clisp.cons.org>
1136 * unicodeio.c (print_unicode_char): Avoid triggering Solaris iconv
1137 bug. Deal with the different error behavior of Irix iconv.
1139 2000-04-07 Jim Meyering <meyering@lucent.com>
1141 * putenv.c: Move inclusion of errno.h so it follows that of sys/types.h,
1142 to work around system header problems on AIX 3.2.5. From Bruno Haible.
1144 2000-04-05 Jim Meyering <meyering@lucent.com>
1146 Portability tweaks required for ultrix4.3.
1147 * readutmp.h [HAVE_UTMPX_H && !HAVE_DECL_GETUTENT]: Declare getutent.
1148 * readutmp.c: Include sys/types.h before sys/stat.h.
1149 * canon-host.c: Declare strdup.
1150 * path-concat.c: Likewise.
1151 From John David Anglin.
1153 2000-04-04 Jim Meyering <meyering@lucent.com>
1155 Be more DOS 8.3-friendly.
1156 * ref-add.sin: Renamed from ref-add.sed.in.
1157 * ref-del.sin: Renamed from ref-del.sed.in.
1158 * Makefile.am: Reflect renaming.
1159 Reported by Eli Zaretskii.
1161 Use a temporary file name that won't clash with `charset.alias'
1162 in the DOS 8.3 name space.
1163 * Makefile.am (charset_tmp): Define.
1164 (install-exec-local): Use $(charset_tmp) instead of $(charset_alias)-t.
1165 (uninstall-local): Likewise.
1166 Reported by Eli Zaretskii.
1168 2000-03-29 Paul Eggert <eggert@twinsun.com>
1170 * time/strftime.c (my_strftime): Make sure we call the system
1171 strftime, not ourselves, when invoking the underlying strftime.
1173 2000-03-24 Jim Meyering <meyering@lucent.com>
1175 * Makefile.am (EXTRA_DIST): Add ref-add.sed.in and ref-del.sed.in.
1176 (charset_alias): Define.
1177 (install-exec-local): Factor out common code.
1178 (uninstall-local): Split lines longer than 80.
1179 (ref-add.sed, ref-del.sed): Remove rules... (do the following instead)
1181 (.sed.in.sed): New rule. Don't redirect directly to $@.
1182 (CLEANFILES): Add ref-add.sed and ref-del.sed.
1184 2000-03-19 Bruno Haible <haible@clisp.cons.org>
1186 * config.charset: Output a line containing "Packages using this file".
1187 * ref-add.sed.in, ref-del.sed.in: New files.
1188 * Makefile.am (install-exec-local, uninstall-local, ref-add.sed,
1189 ref-del.sed): New rules.
1191 2000-03-17 Jim Meyering <meyering@lucent.com>
1193 * unicodeio.c (<string.h>): Include only #if HAVE_STRING_H.
1194 Otherwise, include <strings.h>
1196 2000-03-17 Bruno Haible <haible@clisp.cons.org>
1198 * unicodeio.c (utf8_wctomb): New function.
1199 (print_unicode_char): Pass the Unicode character to iconv in UTF-8
1200 format instead of in UCS-4 with platform dependent endianness.
1202 2000-03-07 Paul Eggert <eggert@twinsun.com>
1204 * savedir.c (savedir): Work even if directory size is
1205 negative; this can happen with some screwy NFS configurations.
1207 2000-03-06 Jim Meyering <meyering@lucent.com>
1209 * localcharset.c (get_charset_aliases): Don't try to free file_name
1210 if it's NULL (because we ran out of memory). From Bruno Haible.
1212 2000-03-05 Jim Meyering <meyering@lucent.com>
1214 * localcharset.c ("path-concat.h"): Include.
1215 (get_charset_aliases): Use path_concat instead of ANSI string
1218 * unicodeio.h (PARAMS): Define.
1219 Use it to guard prototype.
1221 2000-03-04 Jim Meyering <meyering@lucent.com>
1223 * Makefile.am (install-exec-local): Create $(libdir) before installing
1225 (uninstall-local): Uncomment this rule so `make distcheck' works
1228 * unicodeio.c (<errno.h>): Include it.
1229 (errno): Declare if not defined.
1231 * localcharset.c: Add Bruno's comment justifying use of volatile.
1233 * config.charset: New version, incorporating remarks from a linux
1234 i18n mailing list. From Bruno Haible.
1236 2000-03-02 Jim Meyering <meyering@lucent.com>
1238 * Makefile.am (EXTRA_DIST): Add config.charset.
1240 2000-03-01 Jim Meyering <meyering@lucent.com>
1242 * localcharset.c: Guard some #includes with `#if HAVE_...'.
1243 * unicodeio.c: Likewise.
1245 2000-02-02 Bruno Haible <haible@clisp.cons.org>
1247 * config.charset: New file.
1248 * localcharset.c: New file.
1249 * unicodeio.h, unicodeio.c: New files.
1250 * Makefile.am (DEFS): Add -DLIBDIR=...
1251 (libfetish_a_SOURCES): Add localcharset.c and unicodeio.c.
1252 (noinst_HEADERS): Add unicodeio.h.
1253 (all-local, install-exec-local, charset.alias): New targets.
1255 2000-02-28 Paul Eggert <eggert@twinsun.com>
1257 * quotearg.c (ALERT_CHAR): New macro.
1258 (quotearg_buffer_restyled): Use it.
1260 2000-02-27 Jim Meyering <meyering@lucent.com>
1262 * strtoumax.c: Fix typo in decl of strtoul: s/long long/long/.
1263 Guard declaration of strtoull also with `&& HAVE_UNSIGNED_LONG_LONG'.
1265 * backupfile.c: Guard inclusion of stdlib.h with `#if HAVE_STDLIB_H',
1266 not `#if STDC_HEADERS'.
1267 Declare malloc if needed.
1269 * backupfile.c: Use `#if !HAVE_DECL...' instead of `#ifndef HAVE_DECL..'
1270 now that autoconf always defines the HAVE_DECL_ symbols.
1271 * human.c: Likewise.
1273 * strtoumax.c: Likewise.
1275 * backupfile.c: Arrange for cpp to fail if the configure-time
1276 declaration check was not run.
1278 * human.c: Likewise.
1280 * strtoumax.c: Likewise.
1282 * userspec.c (parse_user_spec): If there is no `:' but there is a `.',
1283 then first look up the entire `.'-containing string as a login name.
1285 2000-02-18 Paul Eggert <eggert@twinsun.com>
1287 * getdate.y: Handle two-digit years with leading zeros correctly.
1288 (textint): New typedef.
1289 (parser_control): Member year changed from int to textint.
1291 (YYSTYPE): Removed; replaced by %union with int and textint members.
1292 (tDAY, tDAY_UNIT, tDAYZONE, tHOUR_UNIT, tID, tLOCAL_ZONE, tMERIDIAN,
1293 tMINUTE_UNIT, tMONTH, tMONTH_UNIT tSEC_UNIT, tSNUMBER, tUNUMBER,
1294 tYEAR_UNIT, tZONE, o_merid): Now of type <intval>.
1295 (tSNUMBER, tUNUMBER): Now of type <textintval>.
1296 (date, number, to_year): Use width of number in digits, not its value,
1297 to determine whether it's a 2-digit year, or a 2-digit time.
1298 (yylex): Store number of digits of numeric tokens.
1299 Reported by John Kendall.
1301 (parser_control): Changed from struct parser_control to typedef (for
1302 consistency). All uses changed.
1304 (tID): Removed; not used.
1305 (yylex): Return '?' for unknown identifiers, rather than (unused) tID.
1307 2000-02-14 Paul Eggert <eggert@twinsun.com>
1309 * getpagesize.h (getpagesize): Port to VMS for Alpha;
1310 adapted from changes to grep getpagesize.h by Martin P.J. Zinser.
1312 2000-02-12 Jim Meyering <meyering@lucent.com>
1314 * userspec.c (ISDIGIT): Define it.
1315 (isdigit): Remove definition.
1316 (is_number): Use ISDIGIT, not isdigit.
1317 <libintl.h>: Include.
1319 (parse_user_spec): Mark translatable strings.
1321 2000-02-10 Jim Meyering <meyering@lucent.com>
1323 With these changes, nanosleep.[ch] are finally enough like the other
1324 lib/* replacement files to compile on a few more losing systems.
1326 * nanosleep.h: Don't include config.h.
1327 Remove prototype from declaration of nanosleep.
1328 (PARAMS): Remove now-unneeded definition.
1329 * nanosleep.c: #undef nanosleep.
1330 (rpl_nanosleep): Rename from nanosleep.
1332 2000-02-03 Jim Meyering <meyering@lucent.com>
1334 * readutmp.c (read_utmp): Guard with `#ifdef UTMP_NAME_FUNCTION',
1335 rather than with `#if HAVE_UTMPNAME'.
1337 2000-02-01 Jim Meyering <meyering@lucent.com>
1339 * readutmp.h (UT_USER): Add parens. From Andreas Schwab.
1341 2000-01-31 Jim Meyering <meyering@lucent.com>
1343 * nanosleep.h (nanosleep): Guard declaration with
1344 `#if ! HAVE_DECL_NANOSLEEP'.
1345 Without this, OFS gets a redeclaration error for rpl_nanosleep, due to
1346 the declaration in that vendor's sys/timers.h.
1347 Reported by Christian Krackowizer.
1349 * quotearg.c (ISASCII): Add #undef and move definition to follow
1350 inclusion of wctype.h to work around solaris2.6 namespace pollution.
1351 (ISPRINT): Likewise.
1352 Reported by Tom Tromey.
1354 2000-01-30 Jim Meyering <meyering@lucent.com>
1356 * readutmp.c (extract_trimmed_name): Use UT_USER instead of hard-coding
1357 uses of ->ut_name. The latter doesn't work with new Linux header files
1358 where only utmpx.ut_user is declared.
1360 * readutmp.h (UT_USER): Define.
1362 2000-01-23 Jim Meyering <meyering@lucent.com>
1364 * Makefile.am (libfetish_a_SOURCES): Remove explicit mention of
1367 2000-01-22 Jim Meyering <meyering@lucent.com>
1369 * strtoumax.c: [! HAVE_DECL_STRTOUL]: Declare strtoul.
1370 [! HAVE_DECL_STRTOULL]: Declare strtoull.
1371 Required for some AIX systems. Reported by Christian Krackowizer.
1372 [TESTING] (main): New function.
1374 1997-10-17 Eli Zaretskii <eliz@is.elta.co.il>
1375 * dirname.c (dir_name): Support for DOS-style file names with drive
1378 * quotearg.c [HAVE_WCTYPE_H]: Include <wctype.h> for decl of iswprint.
1380 * strverscmp.c (ISDIGIT): Define.
1381 (strverscmp): Use ISDIGIT, not isdigit.
1383 2000-01-17 Paul Eggert <eggert@twinsun.com>
1385 * nanosleep.c (nanosleep):
1386 Don't use SA_INTERRUPT to decide whether to call sigaction, as
1387 POSIX.1 doesn't require SA_INTERRUPT and some systems
1388 (e.g. Solaris 7) don't define it. Use SA_NOCLDSTOP instead;
1389 it's been part of POSIX.1 since day 1 (in 1988).
1391 2000-01-17 Jim Meyering <meyering@lucent.com>
1393 * interlock: Remove unused file. Reported by François Pinard.
1395 2000-01-16 Paul Eggert <eggert@twinsun.com>
1397 * quotearg.c (quotearg_buffer_restyled): Do not quote
1398 alert, backslash, formfeed, and vertical tab unnecessarily in
1399 shell quoting style.
1402 version-control: never