mirror of
https://git.hardenedbsd.org/hardenedbsd/HardenedBSD.git
synced 2025-01-11 17:04:19 +01:00
Stricter checking %A vs %a
This commit is contained in:
parent
1d6c99412b
commit
7ecd80de13
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=53942
@ -281,17 +281,19 @@ label:
|
||||
case 'A':
|
||||
case 'a':
|
||||
for (i = 0; i < asizeof(Locale->weekday); i++) {
|
||||
len = strlen(Locale->weekday[i]);
|
||||
if (strncasecmp(buf,
|
||||
Locale->weekday[i],
|
||||
len) == 0)
|
||||
break;
|
||||
|
||||
len = strlen(Locale->wday[i]);
|
||||
if (strncasecmp(buf,
|
||||
Locale->wday[i],
|
||||
len) == 0)
|
||||
break;
|
||||
if (c == 'A') {
|
||||
len = strlen(Locale->weekday[i]);
|
||||
if (strncasecmp(buf,
|
||||
Locale->weekday[i],
|
||||
len) == 0)
|
||||
break;
|
||||
} else {
|
||||
len = strlen(Locale->wday[i]);
|
||||
if (strncasecmp(buf,
|
||||
Locale->wday[i],
|
||||
len) == 0)
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (i == asizeof(Locale->weekday))
|
||||
return 0;
|
||||
|
Loading…
Reference in New Issue
Block a user