v->target1 + offset, no?
I don't know about the Lite-C compiler, but pointer arithmetic (not jumping ;)) doesn't work by adding bytes, unless you used bytes to begin with.
int *bar = xyz;
*(bar + 0) = 1024; // First element of the "Array"
*(bar + 1) = 512; // Second element
*(bar + 2) = 32; // Third element
Since the Lite-C compiler packs everything closely anyways (and a pointer is word aligned), target1, target2 and target3 are in fact consecutively laid out in memory, so adding 1 to target1 will result in a pointer pointing to target2.
Sooo...
if(offset == 0)
return v->bmap;
return v->target1 + offset - 1;
Speaking of, you can use return inside a case label
Hm, I don't know if this is helpful but I feel motivated to share things since that good-bye post of Sid
I hope I didn't stop you. I'm off again now anyways, I just clicked here out of old habit...