Without carefully examining your code, I noticed a potential problem with $regml(). $regml() is not local to the routine that calls it, it's like $ifmatch and global variables. Meaning that a child /lema.recurse.thememsg.buildbracematrix would corrupt the while (%j <= $regml(0)) of the parent. You need to use unique names with $regex/$regml to get around this problem ( $regex(name,text,/pattern/) ). From what I see, %node would be a good candidate for a named $regex.


/.timerQ 1 0 echo /.timerQ 1 0 $timer(Q).com