We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents b8a7928 + b1aff1a commit de0cdf9Copy full SHA for de0cdf9
1 file changed
ext/hyper_ruby/src/request.rs
@@ -30,7 +30,7 @@ trait FillBuffer {
30
let existing_capacity = rb_str_capacity(inner) as i64;
31
32
if existing_capacity < body_len {
33
- rb_str_modify_expand(inner, body_len);
+ rb_str_modify_expand(inner, body_len - existing_capacity);
34
} else {
35
rb_str_modify(inner);
36
}
0 commit comments