fix segfault #515
Merge branch 'bugs/515' into releases/tokumx-1.2