(Something of a noob disclaimer applies here as I'm in the midst of my
first serious external making attempt).
vital stats: Max 4.6.3, PPC G4, OS 10.4.11
I'm trying to use a t_linklist in an msp external and am getting crashes
(normally in the gui thread) whenever I re-instantiate my object with
dsp on. Given that the crashes are always in some other thread and they
only started when I started using t_linklist, I'm assuming its a
Having looked at this message by JKC:
I've tried to use a lightweight locking scheme as he suggested, but all
I've achieved with this so far is making my crashes more reproducible.
In my bang method, the list is appended to and sorted and I have
while(myObject->list_being_read); //block if list in perform
myObject->listValid = false;
myObject->listValid = true;
and in perform():
//output zeroes, or something else that doesn't involve reading the
//list and return
myObject->list_being_read = true;
//retreive head, use as basis of output
myObject->list_being_read = false;
Frankly, I'm a bit stumped as to how to hunt down the cause of this.
Given that I only want the linked list for sorting a smallish (
number of things, would I be better off doing something else altogether?
Thanks for any sage advice,