summaryrefslogtreecommitdiff
path: root/packetSource.h
diff options
context:
space:
mode:
authorChristian Pointner <equinox@anytun.org>2008-02-24 00:07:01 +0000
committerChristian Pointner <equinox@anytun.org>2008-02-24 00:07:01 +0000
commit97d40fa80b08194c043a64d2352ca2cbc9be2873 (patch)
tree1819295d33262b386e2c333258bc9f6fd1c07a0b /packetSource.h
parent- keyderivation and cipher should work now (diff)
bugfix@ sender and receiver reset packet size at begin of loop
bugfix@ keyDerivation key_derivation_rate
Diffstat (limited to 'packetSource.h')
-rw-r--r--packetSource.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/packetSource.h b/packetSource.h
index a085b04..81abef8 100644
--- a/packetSource.h
+++ b/packetSource.h
@@ -37,8 +37,8 @@ class PacketSource
public:
virtual ~PacketSource() {}
- virtual u_int32_t recv(Buffer& buf, std::string& addr, u_int16_t &port) = 0;
- virtual void send(Buffer& buf, std::string addr, u_int16_t port) = 0;
+ virtual u_int32_t recv(u_int8_t* buf, u_int32_t len, std::string& addr, u_int16_t &port) = 0;
+ virtual void send(u_int8_t* buf, u_int32_t len, std::string addr, u_int16_t port) = 0;
};
class UDPPacketSource : public PacketSource, public UDPSocket
@@ -48,7 +48,7 @@ public:
UDPPacketSource(u_int16_t port);
UDPPacketSource(std::string localaddr, u_int16_t port);
- u_int32_t recv(Buffer& buf, std::string& addr, u_int16_t &port);
- void send(Buffer& buf, std::string addr, u_int16_t port);
+ u_int32_t recv(u_int8_t* buf, u_int32_t len, std::string& addr, u_int16_t &port);
+ void send(u_int8_t* buf, u_int32_t len, std::string addr, u_int16_t port);
};