Implement GNU extension wcsftime_l
Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
This commit is contained in:
		
							parent
							
								
									463a8afaa5
								
							
						
					
					
						commit
						e636fe3d48
					
				|  | @ -132,6 +132,10 @@ wchar_t	*_EXFUN(_wcsdup_r, (struct _reent *, const wchar_t * )); | |||
| size_t	_EXFUN(wcscspn, (const wchar_t *, const wchar_t *)); | ||||
| size_t  _EXFUN(wcsftime, (wchar_t *__restrict, size_t, | ||||
| 				const wchar_t *__restrict, const struct tm *__restrict)); | ||||
| #if __GNU_VISIBLE | ||||
| size_t  wcsftime_l (wchar_t *__restrict, size_t, const wchar_t *__restrict, | ||||
| 		    const struct tm *__restrict, locale_t); | ||||
| #endif | ||||
| size_t	_EXFUN(wcslcat, (wchar_t *, const wchar_t *, size_t)); | ||||
| size_t	_EXFUN(wcslcpy, (wchar_t *, const wchar_t *, size_t)); | ||||
| size_t	_EXFUN(wcslen, (const wchar_t *)); | ||||
|  |  | |||
|  | @ -311,6 +311,7 @@ locale, hard-coding the "C" locale settings. | |||
| #  define STRLEN(a)	strlen(a) | ||||
| # else | ||||
| #  define strftime	wcsftime	/* Alternate function name */ | ||||
| #  define strftime_l	wcsftime_l	/* Alternate function name */ | ||||
| #  define CHAR		wchar_t		/* string type basis */ | ||||
| #  define CQ(a)		L##a		/* character constant qualifier */ | ||||
| #  define snprintf	swprintf	/* wide-char equivalent function name */ | ||||
|  | @ -1460,9 +1461,8 @@ _DEFUN (strftime, (s, maxsize, format, tim_p), | |||
| #endif /* !_WANT_C99_TIME_FORMATS */ | ||||
| } | ||||
| 
 | ||||
| #if !defined(MAKE_WCSFTIME) | ||||
| size_t | ||||
| strftime_l (char *__restrict s, size_t maxsize, const char *__restrict format, | ||||
| strftime_l (CHAR *__restrict s, size_t maxsize, const CHAR *__restrict format, | ||||
| 	    const struct tm *__restrict tim_p, struct __locale_t *locale) | ||||
| { | ||||
| #ifdef _WANT_C99_TIME_FORMATS | ||||
|  | @ -1479,7 +1479,6 @@ strftime_l (char *__restrict s, size_t maxsize, const char *__restrict format, | |||
|   return __strftime (s, maxsize, format, tim_p, locale, NULL, NULL); | ||||
| #endif /* !_WANT_C99_TIME_FORMATS */ | ||||
| } | ||||
| #endif | ||||
| 
 | ||||
| /* The remainder of this file can serve as a regression test.  Compile
 | ||||
|  *  with -D_REGRESSION_TEST.  */ | ||||
|  |  | |||
|  | @ -1522,6 +1522,7 @@ wcscpy NOSIGFE | |||
| wcscspn NOSIGFE | ||||
| wcsdup NOSIGFE | ||||
| wcsftime SIGFE | ||||
| wcsftime_l SIGFE | ||||
| wcslcat NOSIGFE | ||||
| wcslcpy NOSIGFE | ||||
| wcslen NOSIGFE | ||||
|  |  | |||
		Loading…
	
		Reference in New Issue