Skip to content

res.finished starts as true for HEAD requests from CURL #24283

Closed
@ronag

Description

@ronag

For some reason this fails... which is rather strange?

const assert = require('assert');
const http2 = require('http2');
const fixtures = require('../common/fixtures');

http2
  .createSecureServer({
    allowHTTP1: true,
    key: fixtures.readKey('agent1-key.pem'),
    cert: fixtures.readKey('agent1-cert.pem'),
    ca: fixtures.readKey('ca1-cert.pem')
  })
  .on('request', (req, res) => {
    assert.ok(!res.finished) // AssertionError
  })
  .listen(5001)
curl --head -k https://localhost:5001

Metadata

Metadata

Assignees

No one assigned

    Labels

    http2Issues or PRs related to the http2 subsystem.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions