fix #1096
Merge pull request #1113 from chrox/fix_1096

fix #1096