Tor  0.4.7.0-alpha-dev
Data Structures | Macros
connection_st.h File Reference

Base connection structure. More...

Go to the source code of this file.

Data Structures

struct  connection_t
 

Macros

#define BASE_CONNECTION_MAGIC   0x7C3C304Eu
 
#define OR_CONNECTION_MAGIC   0x7D31FF03u
 
#define EDGE_CONNECTION_MAGIC   0xF0374013u
 
#define ENTRY_CONNECTION_MAGIC   0xbb4a5703
 
#define DIR_CONNECTION_MAGIC   0x9988ffeeu
 
#define CONTROL_CONNECTION_MAGIC   0x8abc765du
 
#define LISTENER_CONNECTION_MAGIC   0x1a1ac741u
 
#define CONN_IS_EDGE(x)    ((x)->type == CONN_TYPE_EXIT || (x)->type == CONN_TYPE_AP)
 
#define DIR_CONN_IS_SERVER(conn)   ((conn)->purpose == DIR_PURPOSE_SERVER)
 

Detailed Description

Base connection structure.

Definition in file connection_st.h.

Macro Definition Documentation

◆ CONN_IS_EDGE

#define CONN_IS_EDGE (   x)     ((x)->type == CONN_TYPE_EXIT || (x)->type == CONN_TYPE_AP)

True iff x is an edge connection.

Definition at line 183 of file connection_st.h.

◆ DIR_CONN_IS_SERVER

#define DIR_CONN_IS_SERVER (   conn)    ((conn)->purpose == DIR_PURPOSE_SERVER)

True iff the purpose of conn means that it's a server-side directory connection.

Definition at line 188 of file connection_st.h.