My attempts to build and run BackupBand from the source were consistently terminatinh with a:
*** buffer overflow detected ***: ./BackupBand terminated
That appears to be because my (glibc?) library's strcpy() is smarter than the average and refuses to write if it thinks the destination string is too small for the data.
As a workaround or possible step towards a fix, for the present I've done the following:
#pragma pack(1)
typedef struct {
STYLE_VARIATION * BassPtns[5];
STYLE_VARIATION * GtrPtns[5];
STYLE_VARIATION * DrumPtns[5];
unsigned char StyleFlags;
unsigned char BassPgm;
unsigned char GtrPgm;
unsigned char DrumPgm;
unsigned char Tempo;
unsigned char MeasureLen;
//char Name[1];
char Name[64];// <-------
} STYLE;
struct STYLEHEAD {
struct STYLEHEAD * Next;
STYLE Style;
};
Whether that is a best-choice fix is moot.
I'd previously tried an abstracted pointer, but it still aborted, so in this instance, the library appears "too clever by half".