Remove pointless playing with LC_TIME, which should have been done in r205821.

This commit is contained in:
Gleb Smirnoff 2019-09-10 04:01:41 +00:00
parent 0b12ab8111
commit 1e01d2dcac
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=352115

View File

@ -50,7 +50,6 @@ int year1, year2;
void
settimes(time_t now, int before, int after, int friday, struct tm *tp1, struct tm *tp2)
{
char *oldl, *lbufp;
struct tm tp;
localtime_r(&now, &tp);
@ -68,15 +67,6 @@ settimes(time_t now, int before, int after, int friday, struct tm *tp1, struct t
strftime(dayname, sizeof(dayname) - 1, "%A, %d %B %Y", tp1);
oldl = NULL;
lbufp = setlocale(LC_TIME, NULL);
if (lbufp != NULL && (oldl = strdup(lbufp)) == NULL)
errx(1, "cannot allocate memory");
(void)setlocale(LC_TIME, "C");
(void)setlocale(LC_TIME, (oldl != NULL ? oldl : ""));
if (oldl != NULL)
free(oldl);
setnnames();
}