This is the mail archive of the
ecos-patches@sources.redhat.com
mailing list for the eCos project.
Warning clean on select.cxx if CYGPKG_POSIX_SIGNALS disabled
- From: sebastien Couret <sebastien dot couret at elios-informatique dot fr>
- To: ecos-patches at sources dot redhat dot com
- Date: Thu, 11 Mar 2004 11:39:51 +0100
- Subject: Warning clean on select.cxx if CYGPKG_POSIX_SIGNALS disabled
- Organization: Elios Informatique
- Reply-to: sebastien dot couret at elios-informatique dot fr
Just a last warning clean for today ;o)
Compiler is issuing a warning on file select.cxx(1.11) line 155 'unused
variable sigset_t oldmask' if posix signals (CYGPKG_POSIX_SIGNALS) are
disabled.
In fact the macro CYG_FILEIO_SIGMASK_SET which takes oldmask as an argument
(see fio.h) is empty if CYGPKG_POSIX_SIGNALS is undefined :
<
#ifdef CYGPKG_POSIX_SIGNALS
#define CYG_FILEIO_SIGMASK_SET( __set, __oset ) \
CYG_PTHREAD_SIGMASK_SET( __set, __oset )
#define CYG_FILEIO_SIGPENDING() CYG_POSIX_SIGPENDING()
#define CYG_FILEIO_DELIVER_SIGNALS( __mask ) \
CYG_POSIX_DELIVER_SIGNALS( __mask )
#else
#define CYG_FILEIO_SIGMASK_SET( __set, __oset ) CYG_EMPTY_STATEMENT
#define CYG_FILEIO_SIGPENDING() (0)
#define CYG_FILEIO_DELIVER_SIGNALS( __mask ) CYG_EMPTY_STATEMENT
typedef int sigset_t;
#endif
>
Here comes the patch :
diff -a -w -u -r 1.11 select.cxx
--- 1.11/select.cxx Thu Mar 11 10:37:15 2004
+++ select.cxx Thu Mar 11 11:30:23 2004
@@ -152,7 +152,9 @@
cyg_tick_count ticks;
int mode_type[] = {CYG_FREAD, CYG_FWRITE, 0};
cyg_uint32 wake_count;
+#ifdef CYGPKG_POSIX_SIGNALS
sigset_t oldmask;
+#endif
FD_ZERO(&in_res);
FD_ZERO(&out_res);
Thanks for all the good work of all eCOS maintainers and developpers !
Have a nice day.