mmapstorage: check msync return value (critical)
@@ -1539,7 +1539,10 @@ int ELEKTRA_PLUGIN_FUNCTION (set) (Plugin * handle ELEKTRA_UNUSED, KeySet * ks,
MmapFooter mmapFooter;
initFooter (&mmapFooter);
- copyKeySetToMmap (mappedRegion, ks, global, &mmapHeader, &mmapMetaData, &mmapFooter, dynArray, mode);
+ if (copyKeySetToMmap (mappedRegion, ks, global, &mmapHeader, &mmapMetaData, &mmapFooter, dynArray, mode) != 0)
+ {
+ goto error;
+ }
if (test_bit (mode, MODE_NONREGULAR_FILE))
{
