mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-07-21 13:49:04 -04:00
Massive commit - changing from sockaddr_in => sockaddr_storage.
In preparation for making RS support IPv6. NB: This breaks the build of retroshare-gui, as the sockaddr_storage_xxx fns are only defined as prototypes for now. All the aux libraries like udp / stun / tcponudp / dht have still to be converted. These changes will probably break various things and need to be tested thoroughly. git-svn-id: http://svn.code.sf.net/p/retroshare/code/branches/v0.6-initdev@6735 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
parent
fd071161bf
commit
6290d8fed9
66 changed files with 1182 additions and 1046 deletions
|
@ -34,6 +34,20 @@
|
|||
#include "serialiser/rstlvtypes.h"
|
||||
#include "util/rsnet.h"
|
||||
|
||||
class RsTlvIpAddress: public RsTlvItem
|
||||
{
|
||||
public:
|
||||
RsTlvIpAddress();
|
||||
virtual ~RsTlvIpAddress() { return; }
|
||||
virtual uint32_t TlvSize();
|
||||
virtual void TlvClear();
|
||||
virtual bool SetTlv(void *data, uint32_t size, uint32_t *offset); /* serialise */
|
||||
virtual bool GetTlv(void *data, uint32_t size, uint32_t *offset); /* deserialise */
|
||||
virtual std::ostream &print(std::ostream &out, uint16_t indent);
|
||||
|
||||
struct sockaddr_storage addr; // Mandatory :
|
||||
};
|
||||
|
||||
|
||||
class RsTlvIpAddressInfo: public RsTlvItem
|
||||
{
|
||||
|
@ -46,7 +60,7 @@ virtual bool SetTlv(void *data, uint32_t size, uint32_t *offset); /* seriali
|
|||
virtual bool GetTlv(void *data, uint32_t size, uint32_t *offset); /* deserialise */
|
||||
virtual std::ostream &print(std::ostream &out, uint16_t indent);
|
||||
|
||||
struct sockaddr_in addr; // Mandatory :
|
||||
RsTlvIpAddress addr; // Mandatory :
|
||||
uint64_t seenTime; // Mandatory :
|
||||
uint32_t source; // Mandatory :
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue