This fixes #7707.