diff options
| author | Anton <anton@picapica> | 2016-12-04 22:46:43 +0400 |
|---|---|---|
| committer | Anton <anton@picapica> | 2016-12-04 22:46:43 +0400 |
| commit | 158d5b71b968d17c7b50d77302ee73466cb099fe (patch) | |
| tree | f555c9396f755b329b7d7745796cb7cb8745bfb0 /PICA_client.h | |
| parent | 29474a9aa7375cef44788b4a2dad8ab137d75748 (diff) | |
| download | pica-pica-158d5b71b968d17c7b50d77302ee73466cb099fe.tar.gz pica-pica-158d5b71b968d17c7b50d77302ee73466cb099fe.zip | |
implementing outgoing direct c2c connections and direct c2c-related packets exchange, work in progress
Diffstat (limited to 'PICA_client.h')
| -rw-r--r-- | PICA_client.h | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/PICA_client.h b/PICA_client.h index 2dbd1bf..afe51de 100644 --- a/PICA_client.h +++ b/PICA_client.h @@ -114,6 +114,8 @@ typedef unsigned __int64 uint64_t; #define PICA_C2C_INCOMING 0 #define PICA_C2C_OUTGOING 1 +#define PICA_DIRECTC2C_INCOMING 0 +#define PICA_DIRECTC2C_OUTGOING 1 struct PICA_c2n; struct PICA_c2c; @@ -191,9 +193,16 @@ enum PICA_directc2c_state struct PICA_c2c_direct { + int is_outgoing; SOCKET sck; SSL *ssl; X509 *peer_cert; + + uint8_t *addrlist; + uint8_t *addrpos; + + struct sockaddr_in addr; + struct PICA_c2c_direct *next; }; @@ -206,8 +215,6 @@ struct PICA_c2c SSL *ssl; struct PICA_c2c_direct *direct; - uint8_t *directc2c_addrlist; - uint8_t *directc2c_addrpos; int outgoing;//1 если создание канала инициировано локальным клиентом, 0 - если собеседником X509 *peer_cert; |
