index : pacman | |
Archlinux32 fork of pacman | gitolite user |
summaryrefslogtreecommitdiff |
author | Allan McRae <allan@archlinux.org> | 2013-07-21 16:38:17 +1000 |
---|---|---|
committer | Allan McRae <allan@archlinux.org> | 2013-07-30 13:01:26 +1000 |
commit | d7bd40045c5a8c1240800bddf61ddac3fa4bd3d2 (patch) | |
tree | d60fe355b76701c3f400846ef6403d2e48ae9edd /lib | |
parent | e81faa9d6d2ac910720a9a87a9f469b80cf106e5 (diff) |
-rw-r--r-- | lib/libalpm/util.c | 15 |
diff --git a/lib/libalpm/util.c b/lib/libalpm/util.c index 1e213627..f1f760a5 100644 --- a/lib/libalpm/util.c +++ b/lib/libalpm/util.c @@ -31,7 +31,6 @@ #include <errno.h> #include <limits.h> #include <sys/wait.h> -#include <locale.h> /* setlocale */ #include <fnmatch.h> /* libarchive */ @@ -1169,20 +1168,6 @@ alpm_time_t _alpm_parsedate(const char *line) long long result; errno = 0; - if(isalpha((unsigned char)line[0])) { - const char *oldlocale; - /* initialize to null in case of failure */ - struct tm tmp_tm; - memset(&tmp_tm, 0, sizeof(struct tm)); - - oldlocale = setlocale(LC_TIME, NULL); - setlocale(LC_TIME, "C"); - strptime(line, "%a %b %e %H:%M:%S %Y", &tmp_tm); - setlocale(LC_TIME, oldlocale); - - return (alpm_time_t)mktime(&tmp_tm); - } - result = strtoll(line, &end, 10); if(result == 0 && end == line) { /* line was not a number */ |