issue #305. prevent resultset loss by placing flock on separate lock file.
Merge pull request #309 from kdeberk/master

issue #305. prevent resultset loss by placing flock on separate lock file