Skip to content

Commit

Permalink
moved platform_util.hpp, puff.hpp and union_endpoint.hpp to aux
Browse files Browse the repository at this point in the history
  • Loading branch information
aldenml authored and arvidn committed Jan 9, 2021
1 parent b47eb1a commit eb62b96
Show file tree
Hide file tree
Showing 11 changed files with 21 additions and 21 deletions.
6 changes: 3 additions & 3 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -77,10 +77,8 @@ set(libtorrent_include_files
pex_flags
piece_block
piece_picker
platform_util
portmap
proxy_base
puff
random
read_resume_data
session
Expand All @@ -107,7 +105,6 @@ set(libtorrent_include_files
torrent_info
torrent_status
tracker_event
union_endpoint
units
upnp
version
Expand Down Expand Up @@ -214,11 +211,13 @@ set(libtorrent_aux_include_files
peer_connection
peer_list
piece_block_progress
platform_util
polymorphic_socket
pool
portmap
posix_part_file
proxy_settings
puff
range
receive_buffer
request_blocks
Expand Down Expand Up @@ -256,6 +255,7 @@ set(libtorrent_aux_include_files
tracker_manager
udp_socket
udp_tracker_connection
union_endpoint
unique_ptr
utf8
utp_socket_manager
Expand Down
6 changes: 3 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -477,11 +477,9 @@ HEADERS = \
pex_flags.hpp \
piece_block.hpp \
piece_picker.hpp \
platform_util.hpp \
portmap.hpp \
posix_disk_io.hpp \
proxy_base.hpp \
puff.hpp \
random.hpp \
read_resume_data.hpp \
session.hpp \
Expand Down Expand Up @@ -510,7 +508,6 @@ HEADERS = \
torrent_info.hpp \
torrent_status.hpp \
tracker_event.hpp \
union_endpoint.hpp \
units.hpp \
upnp.hpp \
version.hpp \
Expand Down Expand Up @@ -590,12 +587,14 @@ HEADERS = \
aux_/peer_connection.hpp \
aux_/peer_list.hpp \
aux_/piece_block_progress.hpp \
aux_/platform_util.hpp \
aux_/polymorphic_socket.hpp \
aux_/pool.hpp \
aux_/portmap.hpp \
aux_/posix_part_file.hpp \
aux_/posix_storage.hpp \
aux_/proxy_settings.hpp \
aux_/puff.hpp \
aux_/range.hpp \
aux_/receive_buffer.hpp \
aux_/request_blocks.hpp \
Expand Down Expand Up @@ -635,6 +634,7 @@ HEADERS = \
aux_/tracker_manager.hpp \
aux_/udp_socket.hpp \
aux_/udp_tracker_connection.hpp \
aux_/union_endpoint.hpp \
aux_/unique_ptr.hpp \
aux_/utf8.hpp \
aux_/utp_socket_manager.hpp \
Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,13 @@
#ifndef TORRENT_PLATFORM_UTIL_HPP
#define TORRENT_PLATFORM_UTIL_HPP

#include "libtorrent/aux_/export.hpp"

#include <cstdint>

namespace libtorrent {
namespace libtorrent::aux {

int max_open_files();
TORRENT_EXTRA_EXPORT int max_open_files();

}

Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion include/libtorrent/aux_/tracker_manager.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ see LICENSE file.
#include "libtorrent/peer_id.hpp"
#include "libtorrent/aux_/peer.hpp" // peer_entry
#include "libtorrent/deadline_timer.hpp"
#include "libtorrent/union_endpoint.hpp"
#include "libtorrent/aux_/union_endpoint.hpp"
#include "libtorrent/io_context.hpp"
#include "libtorrent/span.hpp"
#include "libtorrent/time.hpp"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ see LICENSE file.
#include "libtorrent/socket.hpp"
#include "libtorrent/address.hpp"

namespace libtorrent {
namespace libtorrent::aux {

struct union_address
{
Expand Down
10 changes: 4 additions & 6 deletions include/libtorrent/kademlia/node_entry.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,11 @@ see LICENSE file.
#include "libtorrent/kademlia/node_id.hpp"
#include "libtorrent/socket.hpp"
#include "libtorrent/address.hpp"
#include "libtorrent/union_endpoint.hpp"
#include "libtorrent/aux_/union_endpoint.hpp"
#include "libtorrent/time.hpp" // for time_point
#include "libtorrent/aux_/time.hpp" // for time_now

namespace libtorrent {
namespace dht {
namespace libtorrent::dht {

struct TORRENT_EXTRA_EXPORT node_entry
{
Expand Down Expand Up @@ -55,7 +54,7 @@ struct TORRENT_EXTRA_EXPORT node_entry

node_id id{nullptr};

union_endpoint endpoint;
aux::union_endpoint endpoint;

// the average RTT of this node
std::uint16_t rtt = 0xffff;
Expand All @@ -68,7 +67,6 @@ struct TORRENT_EXTRA_EXPORT node_entry
bool verified = false;
};

} // namespace dht
} // namespace libtorrent
} // namespace libtorrent::dht

#endif
2 changes: 1 addition & 1 deletion src/gzip.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ see LICENSE file.
*/

#include "libtorrent/assert.hpp"
#include "libtorrent/puff.hpp"
#include "libtorrent/aux_/puff.hpp"
#include "libtorrent/gzip.hpp"

#include <string>
Expand Down
4 changes: 2 additions & 2 deletions src/platform_util.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ see LICENSE file.
*/

#include "libtorrent/config.hpp"
#include "libtorrent/platform_util.hpp"
#include "libtorrent/aux_/platform_util.hpp"

#include <cstdint>
#include <limits>
Expand Down Expand Up @@ -39,7 +39,7 @@ const rlim_t rlim_infinity = RLIM_INFINITY;

#include "libtorrent/aux_/disable_warnings_pop.hpp"

namespace libtorrent {
namespace libtorrent::aux {

int max_open_files()
{
Expand Down
2 changes: 1 addition & 1 deletion src/puff.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@

#include <csetjmp> /* for setjmp(), longjmp(), and jmp_buf */
#include <cstring> /* for nullptr */
#include "libtorrent/puff.hpp" /* prototype for puff() */
#include "libtorrent/aux_/puff.hpp" /* prototype for puff() */

#define local static /* for local function definitions */

Expand Down
2 changes: 1 addition & 1 deletion src/session_impl.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ see LICENSE file.
#include "libtorrent/torrent_handle.hpp"
#include "libtorrent/aux_/choker.hpp"
#include "libtorrent/error.hpp"
#include "libtorrent/platform_util.hpp"
#include "libtorrent/aux_/platform_util.hpp"
#include "libtorrent/aux_/bind_to_device.hpp"
#include "libtorrent/hex.hpp" // to_hex, from_hex
#include "libtorrent/aux_/scope_end.hpp"
Expand Down

0 comments on commit eb62b96

Please sign in to comment.