Commit 7ad1cc6
committed
Cygwin: dll_init: Don't call dll::init() twice for DLL_LOAD.
If dlopen() for DLL A is called in constructor DLL B, the constructor
for DLL A is called twice, once called via cygwin_attach_dll() called
from LoadLibrary(), and again from dll_list::init(). That is, the DLL
with DLL_LOAD does not need dll::init() in dll_list::init(). This issue
was found when debugging the issue:
https://cygwin.com/pipermail/cygwin/2025-October/258877.html
This patch remove dll::init() call in dll_list::init() for DLL_LOAD.
Fixes: 2eb392b ("dll_init.cc: Revamp. Use new classes.")
Reviewed-by: Mark Geisert <mark@maxrnd.com>, Jon Turney <jon.turney@dronecode.org.uk>, Corinna Vinschen <corinna-cygwin@cygwin.com>
Signed-off-by: Takashi Yano <takashi.yano@nifty.ne.jp>
(cherry picked from commit d77cb8e)1 parent 1b1f0d8 commit 7ad1cc6
1 file changed
Lines changed: 3 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
618 | 618 | | |
619 | 619 | | |
620 | 620 | | |
621 | | - | |
| 621 | + | |
| 622 | + | |
622 | 623 | | |
623 | | - | |
| 624 | + | |
624 | 625 | | |
625 | 626 | | |
626 | 627 | | |
| |||
0 commit comments