Skip to content

Signals are still reported as error even if they are ignored #1472

Closed
@alokedesai

Description

@alokedesai

Environment

How do you use Sentry?
Sentry SaaS (sentry.io)

Which SDK and version?
sentry.cocoa 7.0.3

Steps to Reproduce

  1. Explicitly ignore SIGIPE: signal(SIGPIPE, SIG_IGN)
  2. Send SIGPIPE to the process (kill -SIGPIPE {pid})

Expected Result

No crash in sentry--the signal was explicitly ignored by Sentry.

Actual Result

A fatal crash in Sentry--I think this because Sentry sets a custom signal handler but doesn't check if the previous handler is SIG_IGN first:

if (sigaction(fatalSignals[i], &action, &g_previousSignalHandlers[i]) != 0) {

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions