fix #1153
Merge pull request #337 from jygaulier/3.7-fix1153

[3.7] Fix #1153