use pthread mutex and condvar rather than guile's
create my_malloc() to track down apparent memory leak