Update of bug #67133 (group groff):

                  Status:             In Progress => Fixed
             Open/Closed:                    Open => Closed
         Planned Release:                    None => 1.24.0

    _______________________________________________________

Follow-up Comment #2:


commit 86a4c9bbe490e6bfdb12c43bb85d249dd29edfae
Author: G. Branden Robinson <[email protected]>
Date:   Fri May 16 19:49:33 2025 -0500

    [groff]: Fix Savannah #67133 (BUILD FAILS).
    
    Fail when piped command gets a SIGPIPE signal.
    
    * src/roff/groff/pipeline.c (run_pipeline) [!_WIN32 && !__MSDOS__ &&
      !_UWIN && !__CYGWIN__ && !__EMX__]: _Unconditionally_ set bit 2 of the
      return value in the event of _any_ signal hitting a pipelined
      process.  A workaround that James Clark put in for a SunOS 4.1.1
      X11-related bug in groff 1.06 (1992) appears to have led us to grief;
      if any of the child processes in the pipeline being wait(2)ed on was
      signaled with SIGPIPE, this alteration of return the value was not
      being done.  If that child was the last in the pipeline (gxditview,
      the code presumes), he walks the list of commands in the pipeline and
      kill(2)s them all with SIGPIPE.  If a process has multiple fatal
      signals pending, which one wins?  Apparently, on Linux 5.10, in a
      fight between SIGPIPE and SIGABRT (raised by abort(3), called by
      assert(3)), SIGPIPE always wins.  So bit 2 of this function's return
      value, which (after a left shift) ultimately becomes groff(1)'s exit
      status, never got set, and so groff happily reported success when it
      should have screamed hideously of failure.  Likely the SunOS 4
      workaround should be ripped out entirely, but this fix adequately
      detects grohtml failures.
    
    Fixes <https://savannah.gnu.org/bugs/?67133>.  Problem appears to date
    back to groff 1.06 (1992).
    
    I experimentally instrumented "pipeline.c" a bit, which helped me track
    down the issue.  The following was as good as a smoking gun to me.
    
    GBR: Unix run_pipeline()
    GBR: PID 54503 caught signal 13
    GBR: run_pipeline() returning 0




    _______________________________________________________

Reply to this item at:

  <https://savannah.gnu.org/bugs/?67133>

_______________________________________________
Message sent via Savannah
https://savannah.gnu.org/

Attachment: signature.asc
Description: PGP signature

Reply via email to