Skip to content

Add protection against concurrent Readers #391

Description

@oslook

During my use of the library(server and client both v1.8.7), the server occasionally receives the following prompt,

failed to get reader: received header with unexpected rsv bits set: false:true:true

which seems to be related to this part of the code.

write.go L300:

	c.writeHeader.rsv1 = false
	if flate && (opcode == opText || opcode == opBinary) {
		c.writeHeader.rsv1 = true
	}

Could you please confirm if it is necessary to add the following code here?

	c.writeHeader.rsv1 = false
	c.writeHeader.rsv2 = false
	c.writeHeader.rsv3 = false

Activity

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

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions