Files
pkgsrc-ng/net/libtorrent/patches/patch-src_data_hash__queue.h
2014-11-05 12:41:07 +01:00

28 lines
743 B
C++

$NetBSD: patch-src_data_hash__queue.h,v 1.3 2013/09/18 16:32:05 joerg Exp $
--- src/data/hash_queue.h.orig 2012-02-17 05:00:42.000000000 +0000
+++ src/data/hash_queue.h
@@ -40,7 +40,13 @@
#include <deque>
#include <map>
#include <pthread.h>
+#if __cplusplus >= 201103L
+#include <functional>
+using std::function;
+#else
#include <tr1/functional>
+using std::tr1::function;
+#endif
#include "torrent/hash_string.h"
#include "hash_queue_node.h"
@@ -63,7 +69,7 @@ public:
typedef std::map<HashChunk*, torrent::HashString> done_chunks_type;
typedef HashQueueNode::slot_done_type slot_done_type;
- typedef std::tr1::function<void (bool)> slot_bool;
+ typedef function<void (bool)> slot_bool;
using base_type::iterator;