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

fix error message for wrong content length on putobject #1140

Merged
merged 1 commit into from
Jul 10, 2019

Conversation

kanagarajkm
Copy link
Contributor

When putObject is called with bigger ContentLength than the actual
object size, Unexpected EOF error is thrown which is not clear.
This happens only with streaming signature.

Now the SteamingReader Read will return a specific error message
saying mismatch in content length, instead of Unexpected EOF.
For example "http: ContentLength=75444 with Body length 70444"

Fixes #1135

When putObject is called with bigger ContentLength than the actual
object size, Unexpected EOF error is thrown which is not clear.
This happens only with streaming signature.

Now the SteamingReader Read will return a specific error message
saying mismatch in content length, instead of Unexpected EOF.
For example "http: ContentLength=75444 with Body length 70444"

Fixes minio#1135
Copy link
Contributor

@sinhaashish sinhaashish left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested & LGTM

Copy link
Contributor

@poornas poornas left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@harshavardhana harshavardhana merged commit a45c90c into minio:master Jul 10, 2019
@lukepighetti
Copy link

Thank you for the quick attention.

@kanagarajkm kanagarajkm deleted the fix-error-msg branch July 11, 2019 19:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Provide explicit error when uploaded file size doesn't match actual size
5 participants