Skip to content

Commit 520b999

Browse files
committed
Replace strncpy with strcpy
1 parent 7e15c54 commit 520b999

1 file changed

Lines changed: 2 additions & 3 deletions

File tree

src/libImaging/Arrow.c

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,6 @@ export_named_type(struct ArrowSchema *schema, char *format, char *name) {
6161
size_t name_len = strlen(name) + 1;
6262

6363
formatp = calloc(format_len, 1);
64-
6564
if (!formatp) {
6665
return IMAGING_CODEC_MEMORY;
6766
}
@@ -72,8 +71,8 @@ export_named_type(struct ArrowSchema *schema, char *format, char *name) {
7271
return IMAGING_CODEC_MEMORY;
7372
}
7473

75-
strncpy(formatp, format, format_len);
76-
strncpy(namep, name, name_len);
74+
strcpy(formatp, format);
75+
strcpy(namep, name);
7776

7877
*schema = (struct ArrowSchema){// Type description
7978
.format = formatp,

0 commit comments

Comments
 (0)