Synced bug fix to HEAD.