blob: 1e84d40d27eccfd01e12c5807541d7b19f1a1c6a (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
|
$FreeBSD$
--- erts/emulator/beam/erl_time_sup.c.orig
+++ erts/emulator/beam/erl_time_sup.c
@@ -648,6 +648,9 @@
t.tm_sec = *second;
t.tm_isdst = isdst;
the_clock = mktime(&t);
+ if (the_clock == -1) {
+ return 0;
+ }
#ifdef HAVE_GMTIME_R
gmtime_r(&the_clock, (tm = &tmbuf));
#else
|