made safe_malloc() of timidity actually safe: it relies on setjmp
and longjmp using a jmp_buf private to timidity. safe_malloc() is
now used only after doing a setjmp(), otherwise we directly use
malloc() and check its return. safe_malloc() does a longjmp() upon
allocation failure: during timidity initialization, jump point is
either mid_init_no_config() or read_config_file(), and a failure
results in a mid_exit() to free all the allocated memory until
that point. if initialization is successful, then safe_malloc() is
used during song loading and a failure jumps to mid_song_load()
resulting in a mid_song_free() to free all memory allocated for
the song until that point. all functions returning safe_malloc'ed
local pointer variables are converted to work properly in case of
a longjmp(). all NULL checks for pointers returned by safe_malloc
are removed. made sure not to leak instrument file pointer upon
longjmp(), i.e. a malloc() failure.
fixed all of the gcc -Wclobbered warnings by fixing my
setjmp/longjmp mistakes including one major thinko in readconfig
recursive calls. made safe_malloc() to 0-fill the memory before
returning. changed sine() macro to use standart M_PI instead of
PI. removed the unused PATH_SEP macro from options.h. defined a
new TIM_MAXPATH, expanding to MAXPATHLEN or PATH_MAX if they are
available or to 1024 otherwise. changed the size of path arrays
to TIM_MAXPATH, instead of the arbitrary number 1024. moved the
inclusion of options.h from the C-sources to timidity_internal.h.
bumped LIBTIMIDITY_VERSION_MINOR to 2, our fork is
noticeably different from original libtimidity-0.1.0