Fix for #8491.