Page MenuHomeFreeBSD

mail: Don't trap signals we shouldn't.
Needs ReviewPublic

Authored by des on Thu, Apr 24, 10:03 PM.

Details

Reviewers
None
Group Reviewers
Klara
Summary

We trap SIGINT, SIGHUP, and tty-related signals when interactive. We
also trap SIGINT when asked to ignore interrupts.

MFC after: 1 week
Sponsored by: Klara, Inc.

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Skipped
Unit
Tests Skipped
Build Status
Buildable 63712
Build 60596: arc lint + arc unit

Event Timeline

des requested review of this revision.Thu, Apr 24, 10:03 PM
kevans added inline comments.
usr.bin/mail/collect.c
82

Looking at the standard, it's not clear to me that this is actually correct. ASYNCHRONOUS EVENTS explciitly spells out ignore handling only in the interactive case as something evaluated when a SIGINT rolls in, and otherwise has:

When mailx is in Send Mode and standard input is not a terminal, it shall take the standard action for all signals.

I think we should continue to leave SIGINT alone in the non-interactive case.