Opened 5 years ago

Closed 5 years ago

#2870 closed merge (fixed)

User signals are not blocked before 'fork' in runInteractiveProcess

Reported by: dsh Owned by: igoo
Priority: high Milestone: 6.10.2
Component: libraries/process Version: 6.10.1
Keywords: threaded runInteractiveProcess Cc:
Operating System: Unknown/Multiple Architecture: x86_64 (amd64)
Type of failure: Difficulty: Unknown
Test Case: Blocked By:
Blocking: Related Tickets:

Description

Hello,

It is possible that the parent process handles user-defined interrupts for the child process. IOManager pipe and generic_handler is inherited in the child process. Pipe and generic_handler are used in threaded RTS.

Although the race window before 'exec' is small.

Regards,
Dmitry

Attachments (1)

patch (726 bytes) - added by dsh 5 years ago.

Download all attachments as: .zip

Change History (5)

Changed 5 years ago by dsh

comment:1 Changed 5 years ago by igloo

  • Difficulty set to Unknown
  • Milestone set to 6.10.2
  • Priority changed from normal to high

Thanks for the patch! We'll take a look for 6.10.2.

comment:2 Changed 5 years ago by simonmar

  • Owner set to simonmar

comment:3 Changed 5 years ago by simonmar

  • Owner changed from simonmar to igoo
  • Type changed from bug to merge

Fixed. Three patches are required, first ghc:

Thu Feb 19 03:34:18 PST 2009  Simon Marlow <marlowsd@gmail.com>
  * Export blockUserSignals and unblockUserSignals (needed for #2870)

secondly for libraries/process:

Thu Feb 19 04:32:35 PST 2009  Simon Marlow <marlowsd@gmail.com>
  * Fix #2870: User signals are not blocked before 'fork' in runInteractiveProcess

and finally, for libraries/base, this isn't strictly necessary but I think it's prudent:

Thu Feb 19 03:42:17 PST 2009  Simon Marlow <marlowsd@gmail.com>
  * Set the IO manager pipe descriptors to FD_CLOEXEC

comment:4 Changed 5 years ago by igloo

  • Resolution set to fixed
  • Status changed from new to closed

All 3 merged.

Note: See TracTickets for help on using tickets.