fix #274: Segmentation fault: 11