summaryrefslogtreecommitdiff
path: root/sfeed.c
diff options
context:
space:
mode:
authorHiltjo Posthuma <hiltjo@codemadness.org>2015-08-06 17:33:28 +0200
committerHiltjo Posthuma <hiltjo@codemadness.org>2015-08-06 17:33:28 +0200
commit46b756cc19e199c89fe3b090885243d1c501262b (patch)
treeae00f8ba17da484bba074f1128662e68163c2e84 /sfeed.c
parenta917dd06f09b3f15daf8c8f63397468be81ac488 (diff)
sfeed: fix, skip milliseconds for: %Y-%m-%dT%H:%M:%S.000Z
Diffstat (limited to 'sfeed.c')
-rw-r--r--sfeed.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/sfeed.c b/sfeed.c
index 3ba70c9..1e5d7e6 100644
--- a/sfeed.c
+++ b/sfeed.c
@@ -233,6 +233,11 @@ gettimetz(const char *s, char *buf, size_t bufsiz, int *tzoffset)
int tzhour = 0, tzmin = 0, r;
size_t i;
+ /* skip milliseconds for: %Y-%m-%dT%H:%M:%S.000Z */
+ if (*s == '.') {
+ for (s++; *s && isdigit((int)*s); s++)
+ ;
+ }
if (!*s || *s == 'Z' || *s == 'z')
goto time_ok;
/* skip whitespace */