summaryrefslogtreecommitdiffstats
path: root/winsup/cygwin/exceptions.cc
diff options
context:
space:
mode:
authorChristopher Faylor <me@cgf.cx>2007-07-29 05:22:05 +0000
committerChristopher Faylor <me@cgf.cx>2007-07-29 05:22:05 +0000
commitee2984326b89e0a38598c0bdf0aa7c76d865c9ed (patch)
treecf3bf8d00a759c744fe18d2a2207eeae03ae44e6 /winsup/cygwin/exceptions.cc
parent81e98baf8142a92dc0749b0f201a2d9b8cdb270c (diff)
downloadcygnal-ee2984326b89e0a38598c0bdf0aa7c76d865c9ed.tar.gz
cygnal-ee2984326b89e0a38598c0bdf0aa7c76d865c9ed.tar.bz2
cygnal-ee2984326b89e0a38598c0bdf0aa7c76d865c9ed.zip
* cygtls.h (_cygtls::inside_kernel): Move function declaration into _cygtls
class. * exceptions.cc (_cygtls::inside_kernel): Move function definition into _cygtls class. * fhandler.cc (fhandler_base::wait_overlapped): Make return tri-state to detect when there is a EINTR situation. Add a pointer to a length parameter. Move GetOverlappedResult into this function. (fhandler_base::read_overlapped): Accommodate above changes and loop if we receive a restartable signal. (fhandler_base::write_overlapped): Ditto. * fhandler.h (fhandler_base::wait_overlapped): Reflect above changes. * fhandler_fifo.cc (fhandler_fifo::wait): Ditto.
Diffstat (limited to 'winsup/cygwin/exceptions.cc')
-rw-r--r--winsup/cygwin/exceptions.cc8
1 files changed, 4 insertions, 4 deletions
diff --git a/winsup/cygwin/exceptions.cc b/winsup/cygwin/exceptions.cc
index efb7a5448..648a39f43 100644
--- a/winsup/cygwin/exceptions.cc
+++ b/winsup/cygwin/exceptions.cc
@@ -282,13 +282,13 @@ stackdump (DWORD ebp, int open_file, bool isexception)
i == 16 ? " (more stack frames may be present)" : "");
}
-static bool
-inside_kernel (CONTEXT *cx)
+bool
+_cygtls::inside_kernel (CONTEXT *cx)
{
int res;
MEMORY_BASIC_INFORMATION m;
- if (!_my_tls.isinitialized ())
+ if (!isinitialized ())
return true;
memset (&m, 0, sizeof m);
@@ -627,7 +627,7 @@ _cygtls::handle_exceptions (EXCEPTION_RECORD *e, exception_list *frame, CONTEXT
error_code |= 1;
if (e->ExceptionInformation[0]) /* Write access */
error_code |= 2;
- if (!inside_kernel (in)) /* User space */
+ if (!me.inside_kernel (in)) /* User space */
error_code |= 4;
klog (LOG_INFO, "%s[%d]: segfault at %08x rip %08x rsp %08x error %d",
__progname, myself->pid,