Open simon-ess opened 6 months ago
This is similar to what @MarkRivers reported in #53, but not the exact same
What we found is that the following creates a segmentation fault for what I presume to be a similar reason:
record(waveform, "foo") { field(NELM, "100") field(FTVL, "CHAR") info(autosaveFields, "VAL VAL$") }
then the pArray is never initialised in this block: https://github.com/epics-modules/autosave/blob/606903e17/asApp/src/save_restore.c#L1423, since the waveform initially reports the number of max_elements as 0.
max_elements
Note that if you only try to save VAL or VAL$ alone (or if FTVL is not CHAR then this doesn't happen.
VAL
VAL$
FTVL
CHAR
In short, the behaviour of autosave with long strings is a bit bizarre and prone to issues.
This is similar to what @MarkRivers reported in #53, but not the exact same
What we found is that the following creates a segmentation fault for what I presume to be a similar reason:
then the pArray is never initialised in this block: https://github.com/epics-modules/autosave/blob/606903e17/asApp/src/save_restore.c#L1423, since the waveform initially reports the number of
max_elements
as 0.Note that if you only try to save
VAL
orVAL$
alone (or ifFTVL
is notCHAR
then this doesn't happen.In short, the behaviour of autosave with long strings is a bit bizarre and prone to issues.