• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

go-pkgz / rest / 32201953393
97%
master: 97%

Build:
Build:
LAST BUILD BRANCH: refs/tags/v1.24.0
DEFAULT BRANCH: master
Ran 19 Aug 2026 12:38AM UTC
Jobs 1
Files 25
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

19 Aug 2026 12:37AM UTC coverage: 97.186% (+0.2%) from 96.939%
32201953393

Pull #56

github

paskal
fix: order the gzip hijack error path so failures cannot corrupt the body

Closing the stream discarded its error and released the writer before the
hijack was attempted, which cost two things.

A failing Close means truncated gzip output, and a hijack succeeding right
after hid it. That error is returned now.

A failing Hijack left hijacked false with the writer already released, so a
handler carrying on would take the plain path and append raw bytes to a body
already advertised as Content-Encoding: gzip. The writer stays attached on that
path instead, and since it is closed a further write fails with "flate: closed
writer" rather than corrupting the response. The deferred close still returns it
to the pool, and the pool is safe because Reset clears the closed flag.

The writer is only released once Hijack has actually taken the connection.

Reported by umputun on #55.
Pull Request #56: Order the gzip hijack error path so failures cannot corrupt the body

14 of 14 new or added lines in 1 file covered. (100.0%)

1658 of 1706 relevant lines covered (97.19%)

47.32 hits per line

Jobs
ID Job ID Ran Files Coverage
1 32201953393.1 19 Aug 2026 12:38AM UTC 25
97.19
GitHub Action Run
Source Files on build 32201953393
  • Tree
  • List 25
  • Changed 1
  • Source Changed 0
  • Coverage Changed 1
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Pull Request #56
  • PR Base - master (#32198708772)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc