unmarshall *un;
int intret;
bool done;
- pthread_mutex_t m;
- pthread_cond_t c;
+ std::mutex m;
+ std::condition_variable c;
};
void get_refconn(connection **ch);
connection *chan_;
- pthread_mutex_t m_; // protect insert/delete to calls[]
- pthread_mutex_t chan_m_;
+ std::mutex m_; // protect insert/delete to calls[]
+ std::mutex chan_m_;
bool destroy_wait_;
- pthread_cond_t destroy_wait_c_;
+ std::condition_variable destroy_wait_c_;
std::map<int, caller *> calls_;
std::list<unsigned int> xid_rep_window_;
// map proc # to function
std::map<int, handler *> procs_;
- pthread_mutex_t procs_m_; // protect insert/delete to procs[]
- pthread_mutex_t count_m_; //protect modification of counts
- pthread_mutex_t reply_window_m_; // protect reply window et al
- pthread_mutex_t conss_m_; // protect conns_
+ std::mutex procs_m_; // protect insert/delete to procs[]
+ std::mutex count_m_; //protect modification of counts
+ std::mutex reply_window_m_; // protect reply window et al
+ std::mutex conss_m_; // protect conns_
protected:
void make_sockaddr(const char *host, const char *port,
struct sockaddr_in *dst);
-int cmp_timespec(const struct timespec &a, const struct timespec &b);
-void add_timespec(const struct timespec &a, int b, struct timespec *result);
-int diff_timespec(const struct timespec &a, const struct timespec &b);
-
#endif