X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=extlibs%2Ftinydtls%2Fpeer.h;h=41fd943f96ef5180a510c3f9e55683ae180ff86d;hb=edcfc3d2329da7b914771c0dcff5f42c9b74fd93;hp=af7c2052f7ff6895f3e7a188c67420a10319a185;hpb=549444d43315442398cff0bb2801498dedd4e747;p=platform%2Fupstream%2Fiotivity.git diff --git a/extlibs/tinydtls/peer.h b/extlibs/tinydtls/peer.h index af7c205..41fd943 100644 --- a/extlibs/tinydtls/peer.h +++ b/extlibs/tinydtls/peer.h @@ -65,7 +65,7 @@ typedef struct dtls_peer_t { dtls_handshake_parameters_t *handshake_params; } dtls_peer_t; -static inline dtls_security_parameters_t *dtls_security_params_epoch(dtls_peer_t *peer, uint16_t epoch) +INLINE_API dtls_security_parameters_t *dtls_security_params_epoch(dtls_peer_t *peer, uint16_t epoch) { if (peer->security_params[0] && peer->security_params[0]->epoch == epoch) { return peer->security_params[0]; @@ -76,12 +76,12 @@ static inline dtls_security_parameters_t *dtls_security_params_epoch(dtls_peer_t } } -static inline dtls_security_parameters_t *dtls_security_params(dtls_peer_t *peer) +INLINE_API dtls_security_parameters_t *dtls_security_params(dtls_peer_t *peer) { return peer->security_params[0]; } -static inline dtls_security_parameters_t *dtls_security_params_next(dtls_peer_t *peer) +INLINE_API dtls_security_parameters_t *dtls_security_params_next(dtls_peer_t *peer) { if (peer->security_params[1]) dtls_security_free(peer->security_params[1]); @@ -94,7 +94,7 @@ static inline dtls_security_parameters_t *dtls_security_params_next(dtls_peer_t return peer->security_params[1]; } -static inline void dtls_security_params_free_other(dtls_peer_t *peer) +INLINE_API void dtls_security_params_free_other(dtls_peer_t *peer) { dtls_security_parameters_t * security0 = peer->security_params[0]; dtls_security_parameters_t * security1 = peer->security_params[1]; @@ -106,7 +106,7 @@ static inline void dtls_security_params_free_other(dtls_peer_t *peer) peer->security_params[1] = NULL; } -static inline void dtls_security_params_switch(dtls_peer_t *peer) +INLINE_API void dtls_security_params_switch(dtls_peer_t *peer) { dtls_security_parameters_t * security = peer->security_params[1]; @@ -133,7 +133,7 @@ dtls_peer_t *dtls_new_peer(const session_t *session); void dtls_free_peer(dtls_peer_t *peer); /** Returns the current state of @p peer. */ -static inline dtls_state_t dtls_peer_state(const dtls_peer_t *peer) { +INLINE_API dtls_state_t dtls_peer_state(const dtls_peer_t *peer) { return peer->state; } @@ -141,7 +141,7 @@ static inline dtls_state_t dtls_peer_state(const dtls_peer_t *peer) { * Checks if given @p peer is connected. This function returns * @c 1 if connected, or @c 0 otherwise. */ -static inline int dtls_peer_is_connected(const dtls_peer_t *peer) { +INLINE_API int dtls_peer_is_connected(const dtls_peer_t *peer) { return peer->state == DTLS_STATE_CONNECTED; }