Ultimate fix for #848