Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Possible race condition in dataReader's Read method #172

Closed
kayrus opened this issue Dec 2, 2021 · 1 comment
Closed

Possible race condition in dataReader's Read method #172

kayrus opened this issue Dec 2, 2021 · 1 comment
Labels

Comments

@kayrus
Copy link
Contributor

kayrus commented Dec 2, 2021

Running an SMTP server with race detection (go run -race) showed a potential race condition in:

if r.limited {

and

go-smtp/data.go

Line 143 in 30169ac

if r.limited {

and

go-smtp/conn.go

Line 653 in 30169ac

r.limited = false

@emersion emersion added the bug label Dec 21, 2021
@foxcpp
Copy link
Collaborator

foxcpp commented Jan 19, 2022

That seems to indicate that you have Read's on data reader running after Data completes which is not supported. I think we should update documentation to explicitly mention this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants