merge f40872ff2517b511a6d0b537a077b5c0e7da24dd, refs #978