mirror of
https://github.com/freebsd/freebsd-src
synced 2024-11-05 18:22:52 +00:00
Add setlocale LC_TIME
This commit is contained in:
parent
9f23763a01
commit
3fb8ee222b
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=11826
1 changed files with 7 additions and 0 deletions
|
@ -16,6 +16,9 @@
|
|||
#include <ctype.h>
|
||||
#include <netdb.h>
|
||||
#include <pwd.h>
|
||||
#ifdef __FreeBSD__
|
||||
#include <locale.h>
|
||||
#endif
|
||||
|
||||
#ifdef SYSLOG
|
||||
# include <syslog.h>
|
||||
|
@ -142,6 +145,10 @@ void main(int argc, char **argv)
|
|||
string tmp, oline;
|
||||
struct servent *sptr;
|
||||
|
||||
#ifdef __FreeBSD__
|
||||
(void) setlocale(LC_TIME, "");
|
||||
#endif
|
||||
|
||||
if ((cp = rindex(argv[0], '/'))) cp++;
|
||||
else cp = argv[0];
|
||||
(void) Strncpy(progname, cp);
|
||||
|
|
Loading…
Reference in a new issue