This is an adopted version of 8b1e071d. Since 1.7 has a flag to disable this behaviour, I think a better fix is to disable this flag by default.