Can we see a larger piece of code? Is your application multithreaded?