zsh printf's a time_t as a long.  The cast is so that I can send the
same patch upstream (assuming that casting to long long is the correct
fix). Bug found with clang.

- Matthew Martin


Index: patches/patch-Src_Builtins_sched_c
===================================================================
RCS file: patches/patch-Src_Builtins_sched_c
diff -N patches/patch-Src_Builtins_sched_c
--- /dev/null   1 Jan 1970 00:00:00 -0000
+++ patches/patch-Src_Builtins_sched_c  21 Feb 2016 01:23:00 -0000
@@ -0,0 +1,12 @@
+$OpenBSD$
+--- Src/Builtins/sched.c.orig  Fri Feb 19 19:38:11 2016
++++ Src/Builtins/sched.c       Sat Feb 20 11:06:55 2016
+@@ -353,7 +353,7 @@ schedgetfn(UNUSED(Param pm))
+       time_t t;
+ 
+       t = sch->time;
+-      sprintf(tbuf, "%ld", t);
++      sprintf(tbuf, "%lld", (long long) t);
+       if (sch->flags & SCHEDFLAG_TRASH_ZLE)
+           flagstr = "-o";
+       else

Reply via email to