Use newer api when avaliable for byte count