fixed integer related bug in TorrentSocket