+2006-06-02 Tor Lillqvist <tml@novell.com>
+
+ * configure.in: Catch more failure modes of strftime() when
+ presented with conversion specifications %l and %k: On Windows,
+ these just do nothing, you don't get a 'l' or 'k' in the result,
+ which was all we used to test for here. Catch also if strftime()
+ does nothing at all when presented with a format containing
+ unsupported conversion specifications.
+
+ * libedataserver/e-data-server-util.c (e_strftime): The Microsoft
+ strftime() doesn't have %e either.
+
2006-06-01 Jeffrey Stedfast <fejj@novell.com>
* libedataserver/e-msgport.c (e_msgport_get): Loop the reads
time(&rawtime);
timeinfo=localtime(&rawtime);
+ buf[0] = '\0';
strftime(buf, 10, "%l %k", timeinfo);
- if (strstr(buf, "l") || strstr(buf, "k"))
+ if (buf[0] == '\0' || buf[0] == ' ' || strstr(buf, "l") || strstr(buf, "k"))
exit(1);
else
exit(0);
ff = c;
}
+#ifdef G_OS_WIN32
+ /* The Microsoft strftime() doesn't have %e either */
+ ff = ffmt;
+ while ((c = strstr(ff, "%e")) != NULL) {
+ c[1] = 'd';
+ ff = c;
+ }
+#endif
+
ret = strftime(s, max, ffmt, tm);
g_free(ffmt);
return ret;