This is the mail archive of the cygwin@cygwin.com mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

sigaction siginfo_t & SIGSEGV


I'm trying to write an application that can run some code when a certain
memory address is read or written.  
My first theory was to use mprotect to remove read/write permissions
from a section and then catch SIGSEGV, but siginfo_t doesn't seem to be
defined.
Is hooking a signal using the 'sa_sigaction' member of 'struct
sigaction' supported in CygWin?

I noticed that struct siginfo_t is declared in sys/signal.h, but inside
a couple of #ifdef:
#if defined(__rtems__)
#if defined(_POSIX_REALTIME_SIGNALS)

And it doesn't have the member that I need anyways (si_addr).

Does anyone know of any other ways of trapping reads/writes to/from
memory regions?


-Rolf Campbell
Software Designer
Tropic Networks

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]