Fix #1045