changed the way locking is done. queue_count is only used inside threaded_* functions
Merge branch 'v1.5.1' of https://github.com/ornladios/ADIOS into v1.5.1

Fixed locking issues with queue_count and the threaded_* functions.