Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit5e1e47c

Browse files
committed
Ignore SIGSYS during initdb.
This prevents the recently-added probe for shm_open() from crashingon platforms that are impolite enough to deliver a signal rather thanreturning ENOSYS for an unimplemented kernel call. At least on theone known example (HPUX 10.20), ignoring SIGSYS does result in thedesired behavior of getting an ENOSYS error return instead.Per discussion, we might later wish to do this in the backend as well,but for now it seems sufficient to do it in initdb.
1 parent3147acd commit5e1e47c

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

‎src/bin/initdb/initdb.c

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3197,6 +3197,11 @@ setup_signals(void)
31973197
#ifdefSIGPIPE
31983198
pqsignal(SIGPIPE,SIG_IGN);
31993199
#endif
3200+
3201+
/* Prevent SIGSYS so we can probe for kernel calls that might not work */
3202+
#ifdefSIGSYS
3203+
pqsignal(SIGSYS,SIG_IGN);
3204+
#endif
32003205
}
32013206

32023207

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp