symbols export fix and test_ssl fix

This commit is contained in:
Arvid Norberg 2015-04-04 13:31:33 +00:00
parent 721d93cb28
commit fb597ca4b3
2 changed files with 6 additions and 5 deletions

View File

@ -37,6 +37,7 @@ POSSIBILITY OF SUCH DAMAGE.
#include <boost/unordered_map.hpp> #include <boost/unordered_map.hpp>
#include <vector> #include <vector>
#include <utility> #include <utility>
#include "libtorrent/export.hpp"
namespace libtorrent namespace libtorrent
{ {
@ -45,7 +46,7 @@ namespace libtorrent
#ifndef TORRENT_DISABLE_MUTABLE_TORRENTS #ifndef TORRENT_DISABLE_MUTABLE_TORRENTS
// this class is used for mutable torrents, to discover identical files // this class is used for mutable torrents, to discover identical files
// in other torrents. // in other torrents.
struct resolve_links struct TORRENT_EXTRA_EXPORT resolve_links
{ {
struct link_t struct link_t
{ {

View File

@ -86,7 +86,7 @@ int peer_disconnects = 0;
int peer_errors = 0; int peer_errors = 0;
int ssl_peer_disconnects = 0; int ssl_peer_disconnects = 0;
bool on_alert(alert* a) bool on_alert(alert const* a)
{ {
if (peer_disconnected_alert* e = alert_cast<peer_disconnected_alert>(a)) if (peer_disconnected_alert* e = alert_cast<peer_disconnected_alert>(a))
{ {
@ -561,10 +561,10 @@ void test_malicious_peer()
, combine_path("..", combine_path("ssl", "dhparams.pem")) , combine_path("..", combine_path("ssl", "dhparams.pem"))
, "test"); , "test");
std::auto_ptr<alert> a = wait_for_alert(ses1 alert const* a = wait_for_alert(ses1
, torrent_finished_alert::alert_type, "ses1"); , torrent_finished_alert::alert_type, "ses1");
TEST_CHECK(a.get()); TEST_CHECK(a);
if (a.get()) if (a)
{ {
TEST_EQUAL(a->type(), torrent_finished_alert::alert_type); TEST_EQUAL(a->type(), torrent_finished_alert::alert_type);
} }