Skip to content

Commit

Permalink
Minor cleanups.
Browse files Browse the repository at this point in the history
  • Loading branch information
gdamore committed Aug 21, 2021
1 parent 9dfe064 commit d4b9121
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 7 deletions.
10 changes: 5 additions & 5 deletions src/core/socket.h
Original file line number Diff line number Diff line change
Expand Up @@ -41,11 +41,11 @@ extern uint32_t nni_sock_id(nni_sock *);
// Note that each of these should be called without any locks held, since
// the socket can reenter the protocol.

// nni_socket_sendq obtains the upper writeq. The protocol should
// nni_socket_sendq obtains the upper write queue. The protocol should
// receive messages from this, and place them on the appropriate pipe.
extern nni_msgq *nni_sock_sendq(nni_sock *);

// nni_socket_recvq obtains the upper readq. The protocol should
// nni_socket_recvq obtains the upper read queue. The protocol should
// inject incoming messages from pipes to it.
extern nni_msgq *nni_sock_recvq(nni_sock *);

Expand All @@ -54,7 +54,7 @@ extern nni_msgq *nni_sock_recvq(nni_sock *);
extern uint32_t nni_sock_flags(nni_sock *);

// This function is used by the public API to set callbacks. It is
// one of the only cases (the only?) where the socket core understands
// one of the few cases (the only?) where the socket core understands
// the public data types. (Other solutions might exist, but they require
// keeping extra state to support conversion between public and internal
// types.) The second argument is a mask of events for which the callback
Expand Down Expand Up @@ -90,10 +90,10 @@ extern void nni_ctx_close(nni_ctx *);
// nni_ctx_id returns the context ID, which can be used with nni_ctx_find.
extern uint32_t nni_ctx_id(nni_ctx *);

// nni_ctx_recv is an asychronous receive.
// nni_ctx_recv receives asynchronously.
extern void nni_ctx_recv(nni_ctx *, nni_aio *);

// nni_ctx_send is an asychronous receive.
// nni_ctx_send sends asynchronously.
extern void nni_ctx_send(nni_ctx *, nni_aio *);

// nni_ctx_getopt is used to get a context option.
Expand Down
3 changes: 1 addition & 2 deletions src/core/sockimpl.h
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
//
// Copyright 2020 Staysail Systems, Inc. <info@staysail.tech>
// Copyright 2021 Staysail Systems, Inc. <info@staysail.tech>
// Copyright 2018 Capitar IT Group BV <info@capitar.com>
//
// This software is supplied under the terms of the MIT License, a
Expand Down Expand Up @@ -36,7 +36,6 @@ struct nni_dialer {
nni_duration d_maxrtime; // maximum time for reconnect
nni_duration d_currtime; // current time for reconnect
nni_duration d_inirtime; // initial time for reconnect
nni_time d_conntime; // time of last good connect
nni_reap_node d_reap;

#ifdef NNG_ENABLE_STATS
Expand Down

0 comments on commit d4b9121

Please sign in to comment.