Hi, test_man,
Just to clarify a few things. Where did you create this read_lock. Is it in the scope that when you call cmtdiscardlock you can see the handle? The handle is just an int so any integer could be perceived as a valid handle. It sounds like you're discarding the lock in the wrong scope. I would recommend a look at the example in \National Instruments\CVI81\samples\utility\Threading\ThreadedGuessers and see if it helps.
Song D
Regards,
Song Du
Systems Software
National Instruments R&D