Fix #690
merged master