Bug 3481/dev/3481 adjust cflock checking to tokyocabinet db

To be merged in master

Ticket: http://www.rudder-project.org/redmine/issues/3564