sync upstream avhttp , pull in important change