Skip to content

Commit

Permalink
Merge pull request #116 from philipp-classen/support_filesizes_above_2g
Browse files Browse the repository at this point in the history
Fixed an overflow when files were listed that are above 2G
  • Loading branch information
taylorfinnell authored Jul 7, 2024
2 parents 62f38e2 + 5f0d8eb commit 39f4310
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/awscr-s3/object.cr
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ module Awscr::S3
# The time string the `Object` was last modifed
getter last_modified

def initialize(@key : String, @size : Int32, @etag : String, @last_modified : Time)
def initialize(@key : String, @size : Int64, @etag : String, @last_modified : Time)
end

def_equals @key, @size, @etag, @last_modified
Expand Down
2 changes: 1 addition & 1 deletion src/awscr-s3/responses/list_objects_v2.cr
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ module Awscr::S3::Response
objects = [] of Object
xml.array("ListBucketResult/Contents") do |object|
key = object.string("Key")
size = object.string("Size").to_i
size = object.string("Size").to_i64
etag = object.string("ETag")
last_modified = Time.parse(object.string("LastModified"), DATE_FORMAT, Time::Location::UTC)

Expand Down

0 comments on commit 39f4310

Please sign in to comment.