Skip to content

Commit

Permalink
Update.
Browse files Browse the repository at this point in the history
	* time/strftime.c (my_strftime): Add compatibility code for use
	outside glibc.  Patch by Jim Meyering <meyering@ascend.com>.
  • Loading branch information
Ulrich Drepper committed Aug 30, 2000
1 parent db7dc81 commit e668889
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 0 deletions.
3 changes: 3 additions & 0 deletions ChangeLog
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
2000-08-30 Ulrich Drepper <drepper@redhat.com>

* time/strftime.c (my_strftime): Add compatibility code for use
outside glibc. Patch by Jim Meyering <meyering@ascend.com>.

* sysdeps/posix/getaddrinfo.c (gaih_local): uname does not everywhere
return 0 for success but always < 0 on failure.

Expand Down
12 changes: 12 additions & 0 deletions time/strftime.c
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,10 @@ extern char *tzname[];
# include <stddef.h>
# include <stdlib.h>
# include <string.h>
#else
# ifndef HAVE_MEMCPY
# define memcpy(d, s, n) bcopy ((s), (d), (n))
# endif
#endif

#ifdef COMPILE_WIDE
Expand Down Expand Up @@ -816,6 +820,14 @@ my_strftime (s, maxsize, format, tp ut_argument)
char *u = ufmt;
char ubuf[1024]; /* enough for any single format in practice */
size_t len;
/* Make sure we're calling the actual underlying strftime.
In some cases, config.h contains something like
"#define strftime rpl_strftime". */
# ifdef strftime
# undef strftime
size_t strftime ();
# endif

*u++ = '%';
if (modifier != 0)
*u++ = modifier;
Expand Down

0 comments on commit e668889

Please sign in to comment.