#3871: segfault fixed
Merge branch '3871_segfault' into master_x64