[MPlayer-cvslog] r33923 - trunk/stream/cache2.c

diego subversion at mplayerhq.hu
Tue Jul 26 01:16:28 CEST 2011


Author: diego
Date: Tue Jul 26 01:16:28 2011
New Revision: 33923

Log:
cache2: merge struct declaration and member assignment

struct sigaction is not guaranteed to contain a struct or union, so
do not initialize it with a double set of {} to avoid warnings as was
done in a previous commit.  Merging declaration and assignment also
silences the warning without the risk of breaking on some systems.

Modified:
   trunk/stream/cache2.c

Modified: trunk/stream/cache2.c
==============================================================================
--- trunk/stream/cache2.c	Tue Jul 26 01:16:26 2011	(r33922)
+++ trunk/stream/cache2.c	Tue Jul 26 01:16:28 2011	(r33923)
@@ -384,8 +384,7 @@ static void dummy_sighandler(int x) {
 static void cache_mainloop(cache_vars_t *s) {
     int sleep_count = 0;
 #if FORKED_CACHE
-    struct sigaction sa = { { 0 } };
-    sa.sa_handler = SIG_IGN;
+    struct sigaction sa = { .sa_handler = SIG_IGN };
     sigaction(SIGUSR1, &sa, NULL);
 #endif
     do {


More information about the MPlayer-cvslog mailing list