Opened 4 years ago

Closed 4 years ago

#5734 enhancement closed fixed (fixed)

attempt to quash a warning by storing the result of write() in _sigchld.c is unsuccessful

Reported by: glyph Owned by: glyph
Priority: normal Milestone:
Component: core Keywords:
Cc: Branch: branches/store-write-result-sigchld-5734
branch-diff, diff-cov, branch-cov, buildbot
Author: ashfall


We should apply this:

  • twisted/internet/_sigchld.c

    1313static void got_signal(int sig) {
    1414    int saved_errno = errno;
    15     int ignored_result;
     15    ssize_t ignored_result;
    1717    /* write() errors are unhandled.  If the buffer is full, we don't
    1818     * care.  What about other errors? */

since, in fact, write() returns ssize_t and not int. (Sometimes they're the same thing, sometimes not.)

Change History (5)

comment:1 Changed 4 years ago by glyph

  • Keywords review added

comment:2 Changed 4 years ago by ashfall

  • Owner set to ashfall
  • Status changed from new to assigned

comment:3 Changed 4 years ago by ashfall

  • Author set to ashfall
  • Branch set to branches/store-write-result-sigchld-5734

(In [34658]) Branching to 'store-write-result-sigchld-5734'

comment:4 Changed 4 years ago by ashfall

  • Keywords review removed
  • Owner changed from ashfall to glyph
  • Status changed from assigned to new

Looks good to me. Please add a news file and merge.

Build Results

comment:5 Changed 4 years ago by glyph

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

(In [34829]) Merge store-write-result-sigchld-5734

Author: glyph

Reviewer: ashfall

Fixes: #5734

Fix a minor defect in _sigchld.c; store the result of a function in a container declared to be of the correct size, rather than the incorrect size.

Note: See TracTickets for help on using tickets.