fix race condition / timing issue on the internal message map

Fix for https://github.com/fusesource/mqtt-client/issues/26