[pulseaudio-commits] r2448 - in /trunk/src/pulse: timeval.c timeval.h
svnmailer-noreply at 0pointer.de
svnmailer-noreply at 0pointer.de
Sat May 17 02:07:08 PDT 2008
Author: lennart
Date: Sat May 17 11:07:07 2008
New Revision: 2448
URL: http://0pointer.de/cgi-bin/viewcvs.cgi?rev=2448&root=pulseaudio&view=rev
Log:
declare the explicit type for our PA_xSEC_PER_ySEC constants
Modified:
trunk/src/pulse/timeval.c
trunk/src/pulse/timeval.h
Modified: trunk/src/pulse/timeval.c
URL: http://0pointer.de/cgi-bin/viewcvs.cgi/trunk/src/pulse/timeval.c?rev=2448&root=pulseaudio&r1=2447&r2=2448&view=diff
==============================================================================
--- trunk/src/pulse/timeval.c (original)
+++ trunk/src/pulse/timeval.c Sat May 17 11:07:07 2008
@@ -140,7 +140,7 @@
tv->tv_usec += (suseconds_t) v;
/* Normalize */
- while (tv->tv_usec >= PA_USEC_PER_SEC) {
+ while ((unsigned) tv->tv_usec >= PA_USEC_PER_SEC) {
tv->tv_sec++;
tv->tv_usec -= PA_USEC_PER_SEC;
}
Modified: trunk/src/pulse/timeval.h
URL: http://0pointer.de/cgi-bin/viewcvs.cgi/trunk/src/pulse/timeval.h?rev=2448&root=pulseaudio&r1=2447&r2=2448&view=diff
==============================================================================
--- trunk/src/pulse/timeval.h (original)
+++ trunk/src/pulse/timeval.h Sat May 17 11:07:07 2008
@@ -34,12 +34,12 @@
PA_C_DECL_BEGIN
-#define PA_MSEC_PER_SEC 1000
-#define PA_USEC_PER_SEC 1000000
-#define PA_NSEC_PER_SEC 1000000000
-#define PA_USEC_PER_MSEC 1000
-#define PA_NSEC_PER_MSEC 1000000
-#define PA_NSEC_PER_USEC 1000
+#define PA_MSEC_PER_SEC ((pa_usec_t) 1000ULL)
+#define PA_USEC_PER_SEC ((pa_usec_t) 1000000ULL)
+#define PA_NSEC_PER_SEC ((pa_usec_t) 1000000000ULL)
+#define PA_USEC_PER_MSEC ((pa_usec_t) 1000ULL)
+#define PA_NSEC_PER_MSEC ((pa_usec_t) 1000000ULL)
+#define PA_NSEC_PER_USEC ((pa_usec_t) 1000ULL)
struct timeval;
More information about the pulseaudio-commits
mailing list