From: Takashi Yano <takashi.yano@nifty.ne.jp>
To: cygwin@cygwin.com
Subject: cygwin on git master fails to start.
Date: Thu, 28 Jul 2022 23:21:40 +0900 [thread overview]
Message-ID: <20220728232140.f781ed71cbe1794e337ca369@nifty.ne.jp> (raw)
Hi Corinna,
After the following commit, cygwin fails to start in my
environment.
commit e46f15c2d168abea34b4d880b4eba38d750c7066
Author: Corinna Vinschen <corinna@vinschen.de>
Date: Thu Jul 14 20:06:09 2022 +0200
Cygwin: hookapi: drop handling i386 targets
Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
diff --git a/winsup/cygwin/hookapi.cc b/winsup/cygwin/hookapi.cc
index fbf13ce90..3ce1e0fb2 100644
--- a/winsup/cygwin/hookapi.cc
+++ b/winsup/cygwin/hookapi.cc
@@ -39,12 +39,10 @@ PEHeaderFromHModule (HMODULE hModule, bool &is_64bit)
{
pNTHeader = PIMAGE_NT_HEADERS (PBYTE (hModule)
+ PIMAGE_DOS_HEADER (hModule) ->e_lfanew);
- if (pNTHeader->Signature != IMAGE_NT_SIGNATURE)
+ if (pNTHeader->Signature == IMAGE_NT_SIGNATURE)
pNTHeader = NULL;
else if (pNTHeader->FileHeader.Machine == IMAGE_FILE_MACHINE_AMD64)
is_64bit = true;
- else if (pNTHeader->FileHeader.Machine == IMAGE_FILE_MACHINE_I386)
- is_64bit = false;
else
pNTHeader = NULL;
}
Is this the right thing?
- if (pNTHeader->Signature != IMAGE_NT_SIGNATURE)
+ if (pNTHeader->Signature == IMAGE_NT_SIGNATURE)
pNTHeader = NULL;
--
Takashi Yano <takashi.yano@nifty.ne.jp>
next reply other threads:[~2022-07-28 14:21 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-07-28 14:21 Takashi Yano [this message]
2022-07-28 14:46 ` Corinna Vinschen
2022-07-28 15:07 ` Takashi Yano
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20220728232140.f781ed71cbe1794e337ca369@nifty.ne.jp \
--to=takashi.yano@nifty.ne.jp \
--cc=cygwin@cygwin.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).