Buffer overflows
memcpy (field_data->name, field_name, MPI_MAX_PROCESSOR_NAME);
field_name
is a null-terminated C string that is shorter than MPI_MAX_PROCESSOR_NAME
in the heat example (see examples/heat_example/src/heat.c
, line 111. Using memcpy
will cause a memory over-read for all sufficiently short strings. The fix is to use strncpy
:
strncpy(field_data->name, field_name, MPI_MAX_PROCESSOR_NAME);
See also #9 (closed).
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information