diff options
author | Christopher Faylor <me@cgf.cx> | 2004-07-16 15:49:22 +0000 |
---|---|---|
committer | Christopher Faylor <me@cgf.cx> | 2004-07-16 15:49:22 +0000 |
commit | 1d2fd388472d353a9a2c43512d04bb2edff7afa6 (patch) | |
tree | bb2de5f88b27d7e55ad0700a4683913837b7dd7a /winsup/cygwin/pinfo.cc | |
parent | dbfd3394e9b0a7913dd27b0ba0252ec1a212b36e (diff) | |
download | cygnal-1d2fd388472d353a9a2c43512d04bb2edff7afa6.tar.gz cygnal-1d2fd388472d353a9a2c43512d04bb2edff7afa6.tar.bz2 cygnal-1d2fd388472d353a9a2c43512d04bb2edff7afa6.zip |
* pinfo.cc (pinfo::init): Guard against MapViewOfFileEx failure.
Diffstat (limited to 'winsup/cygwin/pinfo.cc')
-rw-r--r-- | winsup/cygwin/pinfo.cc | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/winsup/cygwin/pinfo.cc b/winsup/cygwin/pinfo.cc index 79d4c60d4..f3a91754d 100644 --- a/winsup/cygwin/pinfo.cc +++ b/winsup/cygwin/pinfo.cc @@ -193,6 +193,8 @@ pinfo::init (pid_t n, DWORD flag, HANDLE in_h) } procinfo = (_pinfo *) MapViewOfFileEx (h, access, 0, 0, 0, mapaddr); + if (!procinfo) + api_fatal ("MapViewOfFileEx failed, %E"); ProtectHandle1 (h, pinfo_shared_handle); if ((procinfo->process_state & PID_INITIALIZING) && (flag & PID_NOREDIR) |