openbsd-ports/audio/ncmpcpp/patches/patch-src_clock_cpp
2011-10-13 11:15:41 +00:00

17 lines
426 B
Plaintext

$OpenBSD: patch-src_clock_cpp,v 1.2 2011/10/13 11:15:41 dcoppa Exp $
Unbreak compilation
--- src/clock.cpp.orig Tue Oct 11 21:27:41 2011
+++ src/clock.cpp Thu Oct 13 12:53:07 2011
@@ -113,7 +113,8 @@ void Clock::Update()
static timeval past = { 0, 0 };
gettimeofday(&past, 0);
- tm *time = localtime(&past.tv_sec);
+ time_t tmp = past.tv_sec;
+ tm *time = localtime(&tmp);
mask = 0;
Set(time->tm_sec % 10, 0);