update the receive method to fix gzinflate(): data error