<commit_before>#include <libtorrent/enum_net.hpp>
#include <libtorrent/socket.hpp>
#include <libtorrent/broadcast_socket.hpp>
#include <vector>

using namespace libtorrent;

int main()
{
	io_service ios;
	asio::error_code ec;
	std::vector<ip_interface> const& net = enum_net_interfaces(ios, ec);

	for (std::vector<ip_interface>::const_iterator i = net.begin()
		, end(net.end()); i != end; ++i)
	{
		std::cout << "address: " << i->interface_address << std::endl
			<< "   mask: " << i->netmask << std::endl
			<< "   flags: ";
		if (is_multicast(i->interface_address)) std::cout << "multicast ";
		if (is_local(i->interface_address)) std::cout << "local ";
		if (is_loopback(i->interface_address)) std::cout << "loopback ";
		std::cout << std::endl;
	}

	address local = guess_local_address(ios);

	std::cout << "Local address: " << local << std::endl;
}
<commit_msg>prints out default gateway in example<commit_after>#include <libtorrent/enum_net.hpp>
#include <libtorrent/socket.hpp>
#include <libtorrent/broadcast_socket.hpp>
#include <vector>

using namespace libtorrent;

int main()
{
	io_service ios;
	asio::error_code ec;
	std::vector<ip_interface> const& net = enum_net_interfaces(ios, ec);

	for (std::vector<ip_interface>::const_iterator i = net.begin()
		, end(net.end()); i != end; ++i)
	{
		std::cout << "address: " << i->interface_address << std::endl
			<< "   mask: " << i->netmask << std::endl
			<< "   flags: ";
		if (is_multicast(i->interface_address)) std::cout << "multicast ";
		if (is_local(i->interface_address)) std::cout << "local ";
		if (is_loopback(i->interface_address)) std::cout << "loopback ";
		std::cout << std::endl;
	}

	address local = guess_local_address(ios);
	std::cout << "Local address: " << local << std::endl;

	address gateway = get_default_gateway(ios, local, ec);
	std::cout << "Default gateway: " << gateway << std::endl;
}

{'fraction_non_alphanumeric': 0.1856, 'fraction_numerical': 0.0, 'mean_word_length': 5.191419141914191, 'pattern_counts': {'":': 0, '<': 77, '<?xml version=': 0, '>': 25, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '193393', 'n_tokens_mistral': 698, 'n_tokens_neox': 665, 'n_words': 135}