mirror of
https://github.com/TREX-CoE/trexio.git
synced 2024-11-03 20:54:07 +01:00
safer strncpy in the front end
This commit is contained in:
parent
4fceb6624d
commit
3ce9c57376
@ -1529,8 +1529,8 @@ trexio_write_$group_dset$ (trexio_t* const file, const char* dset, const uint32_
|
||||
}
|
||||
|
||||
dset_str[i]=tmp_str;
|
||||
strncpy(tmp_str, pch, max_str_len);
|
||||
tmp_str += max_str_len + 1;
|
||||
strncpy(tmp_str, pch, pch_len);
|
||||
tmp_str += pch_len + 1;
|
||||
}
|
||||
|
||||
rc = TREXIO_FAILURE;
|
||||
|
Loading…
Reference in New Issue
Block a user