Skip to content

Error while checking for terminated children #30092

Closed

Description

@jkotas

Hit in dotnet/coreclr#25497 on Linux arm checked

  Discovering: JIT.jit64.XUnitWrapper
  Discovered:  JIT.jit64.XUnitWrapper
  Starting:    JIT.jit64.XUnitWrapper
Process terminated. Error while checking for terminated children. errno = 0
   at System.Environment.FailFast(System.String)
   at System.Diagnostics.ProcessWaitState.CheckChildren(Boolean)
   at System.Diagnostics.Process.OnSigChild(Boolean)
Aborted (core dumped)

Activity

  1. stephentoub commented on Jul 1, 2019

    @stephentoub
    Member

    cc: @tmds

  2. tmds commented on Jul 1, 2019

    @tmds
    Member

    This happens when this code returns < 0:

    https://github.com/dotnet/corefx/blob/b10e8d67b260e26f2e47750cf96669e6f48e774d/src/Native/Unix/System.Native/pal_process.c#L639-L654

    The man page says:

    If WNOHANG was specified in options and there were no children in a waitable state, then waitid() returns 0 immediately and the state of the siginfo_t structure pointed to by infop is unspecified. To distinguish this case from that where a child was in a waitable state, zero out the si_pid field before the call and check for a nonzero value in this field after the call returns.

    Maybe this is what is happening here, and siginfo.si_pid contains a < 0 value.
    When I try to reproduce this on x64, I get return -1 with errno ECHILD.
    The error occurred on Ubuntu.1604.Arm32.

    I'll update the code to handle this case.

  3. transferred this issue fromdotnet/corefxon Feb 1, 2020
  4. added this to the 3.0 milestone on Feb 1, 2020
  5. ghost locked as resolved and limited conversation to collaborators on Dec 12, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions