Skip to content

Commit b02dc5b

Browse files
committed
wip
1 parent 239ea28 commit b02dc5b

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/aws/flb_aws_util.c

+3-1
Original file line numberDiff line numberDiff line change
@@ -821,17 +821,19 @@ flb_sds_t flb_get_s3_key(const char *format, time_t time, const char *tag, char
821821
flb_sds_destroy(tmp);
822822

823823
/* A string no longer than S3_KEY_SIZE is created to store the formatted timestamp. */
824-
key = flb_malloc(S3_KEY_SIZE);
824+
key = flb_malloc(S3_KEY_SIZE * sizeof(char));
825825
if (!key) {
826826
goto error;
827827
}
828828
flb_warn("alloc'd %d bytes", S3_KEY_SIZE);
829+
flb_warn("key=%p", key);
829830

830831
ret = strftime(key, S3_KEY_SIZE, s3_key, gmt);
831832
if(ret == 0){
832833
flb_warn("[s3_key] Object key length is longer than the 1024 character limit.");
833834
}
834835
flb_warn("key: %s, len(key): %d", key, strlen(key));
836+
flb_warn("key=%p", key);
835837

836838
flb_sds_destroy(s3_key);
837839
s3_key = flb_sds_create(key);

0 commit comments

Comments
 (0)