compatibility fixes for libtorrent 1.0 (trunk)