Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -178,6 +178,7 @@ pub mod toxcore_tests {
pub mod toxcore {
#[macro_use]
pub mod binary_io;
pub mod binary_io_new;
pub mod crypto_core;
pub mod dht;
pub mod dht_node;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,12 +19,11 @@
along with Tox. If not, see <http://www.gnu.org/licenses/>.
*/

/*! Encoding/decoding traits for TCP mod
/*! Encoding/decoding traits
*/

// FIXME: merge with toxcore/binary_io.rs

use toxcore::crypto_core::*;

pub use nom::IResult;
pub use cookie_factory::GenError;

Expand Down
1 change: 0 additions & 1 deletion src/toxcore/dht_new/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,5 @@
*/

pub mod packet;
pub mod binary_io;
pub mod kbucket;
pub mod packed_node;
2 changes: 1 addition & 1 deletion src/toxcore/dht_new/packed_node.rs
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ use std::net::{
SocketAddr,
};

use toxcore::dht_new::binary_io::*;
use toxcore::binary_io_new::*;
use toxcore::crypto_core::*;

/** `PackedNode` format is a way to store the node info in a small yet easy to
Expand Down
2 changes: 1 addition & 1 deletion src/toxcore/dht_new/packet.rs
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ use std::net::{
Ipv6Addr,
};

use toxcore::dht_new::binary_io::*;
use toxcore::binary_io_new::*;
use toxcore::crypto_core::*;
use toxcore::dht_new::packed_node::PackedNode;

Expand Down
50 changes: 0 additions & 50 deletions src/toxcore/tcp/binary_io.rs

This file was deleted.

2 changes: 1 addition & 1 deletion src/toxcore/tcp/codec.rs
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,9 @@
/*! Codec implementation for encoding/decoding TCP Packets in terms of tokio-io
*/

use toxcore::binary_io_new::*;
use toxcore::tcp::packet::*;
use toxcore::tcp::secure::*;
use toxcore::tcp::binary_io::*;

use nom::Offset;
use std::io::{Error, ErrorKind};
Expand Down
2 changes: 1 addition & 1 deletion src/toxcore/tcp/handshake/codec.rs
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@

*/

use toxcore::binary_io_new::*;
use toxcore::tcp::handshake::packet::*;
use toxcore::tcp::binary_io::*;

use nom::Offset;
use bytes::BytesMut;
Expand Down
2 changes: 1 addition & 1 deletion src/toxcore/tcp/handshake/packet.rs
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,8 @@ handshake using [`diagram`](https://zetok.github.io/tox-spec/#handshake-diagram)

*/

use toxcore::binary_io_new::*;
use toxcore::crypto_core::*;
use toxcore::tcp::binary_io::*;

/** The request of the client to create a TCP handshake.

Expand Down
3 changes: 1 addition & 2 deletions src/toxcore/tcp/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -23,17 +23,16 @@

*/

use toxcore::binary_io_new::*;
use toxcore::crypto_core::*;

pub mod binary_io;
pub mod handshake;
pub mod secure;
pub mod packet;
pub mod codec;
pub mod server;

use self::handshake::*;
use self::binary_io::*;

use futures::{self, Stream, Sink, Future};
use std::io::{Error, ErrorKind};
Expand Down
2 changes: 1 addition & 1 deletion src/toxcore/tcp/packet.rs
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@
to [Tox spec](https://zetok.github.io/tox-spec/#encrypted-payload-types)
*/

use toxcore::binary_io_new::*;
use toxcore::crypto_core::*;
use toxcore::tcp::binary_io::*;

use nom::{be_u8, be_u16, be_u64, rest};

Expand Down