Skip to content

Commit

Permalink
Merge pull request #1 from sdt/final-boundary
Browse files Browse the repository at this point in the history
Fix out-by-one error on last_boundary
  • Loading branch information
reneeb committed Jun 5, 2015
2 parents 1691b54 + 85c6440 commit d02f324
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/HTTP/Tiny/Multipart.pm
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ no warnings 'redefine';
my $boundary = _get_boundary($headers, $content_parts);

my $last_boundary = $boundary;
substr $last_boundary, -3, 0, "--";
substr $last_boundary, -2, 0, "--";

return $self->request('POST', $url, {
%$args,
Expand Down

0 comments on commit d02f324

Please sign in to comment.