Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
L
libzmq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
submodule
libzmq
Commits
9b67fe8a
Unverified
Commit
9b67fe8a
authored
Dec 09, 2019
by
Doron Somech
Committed by
GitHub
Dec 09, 2019
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #3755 from sigiesec/more-improvements-analyze
Make use of = default and = delete if available
parents
400107d7
b88b12c7
Hide whitespace changes
Inline
Side-by-side
Showing
100 changed files
with
180 additions
and
271 deletions
+180
-271
.travis.yml
.travis.yml
+2
-0
array.hpp
src/array.hpp
+6
-8
atomic_counter.hpp
src/atomic_counter.hpp
+1
-2
atomic_ptr.hpp
src/atomic_ptr.hpp
+1
-2
client.hpp
src/client.hpp
+1
-2
clock.hpp
src/clock.hpp
+2
-2
condition_variable.hpp
src/condition_variable.hpp
+7
-24
ctx.hpp
src/ctx.hpp
+1
-2
dbuffer.hpp
src/dbuffer.hpp
+1
-3
dealer.hpp
src/dealer.hpp
+1
-2
decoder.hpp
src/decoder.hpp
+1
-2
decoder_allocators.hpp
src/decoder_allocators.hpp
+1
-2
devpoll.hpp
src/devpoll.hpp
+1
-2
dgram.hpp
src/dgram.hpp
+1
-2
dish.hpp
src/dish.hpp
+2
-4
dist.hpp
src/dist.hpp
+2
-2
encoder.hpp
src/encoder.hpp
+2
-3
epoll.hpp
src/epoll.hpp
+1
-2
fq.hpp
src/fq.hpp
+1
-2
gather.hpp
src/gather.hpp
+1
-2
generic_mtrie.hpp
src/generic_mtrie.hpp
+2
-3
i_decoder.hpp
src/i_decoder.hpp
+2
-1
i_encoder.hpp
src/i_encoder.hpp
+2
-1
i_engine.hpp
src/i_engine.hpp
+2
-1
i_mailbox.hpp
src/i_mailbox.hpp
+2
-1
i_poll_events.hpp
src/i_poll_events.hpp
+3
-1
io_object.hpp
src/io_object.hpp
+1
-2
io_thread.hpp
src/io_thread.hpp
+1
-2
ipc_address.hpp
src/ipc_address.hpp
+5
-4
ipc_connecter.hpp
src/ipc_connecter.hpp
+1
-2
ipc_listener.hpp
src/ipc_listener.hpp
+1
-2
kqueue.hpp
src/kqueue.hpp
+1
-2
lb.hpp
src/lb.hpp
+1
-2
macros.hpp
src/macros.hpp
+26
-0
mailbox.hpp
src/mailbox.hpp
+1
-3
mailbox_safe.hpp
src/mailbox_safe.hpp
+1
-3
metadata.hpp
src/metadata.hpp
+2
-3
mutex.hpp
src/mutex.hpp
+6
-15
object.hpp
src/object.hpp
+4
-3
own.hpp
src/own.hpp
+1
-2
pair.hpp
src/pair.hpp
+1
-2
pgm_receiver.hpp
src/pgm_receiver.hpp
+1
-2
pgm_sender.hpp
src/pgm_sender.hpp
+1
-2
pipe.hpp
src/pipe.hpp
+2
-4
poll.hpp
src/poll.hpp
+1
-2
poller_base.hpp
src/poller_base.hpp
+1
-2
polling_util.hpp
src/polling_util.hpp
+5
-6
pollset.hpp
src/pollset.hpp
+1
-2
pub.hpp
src/pub.hpp
+1
-3
pull.hpp
src/pull.hpp
+1
-2
push.hpp
src/push.hpp
+1
-2
radio.hpp
src/radio.hpp
+2
-4
raw_decoder.hpp
src/raw_decoder.hpp
+1
-2
raw_encoder.hpp
src/raw_encoder.hpp
+1
-2
raw_engine.hpp
src/raw_engine.hpp
+1
-2
reaper.hpp
src/reaper.hpp
+2
-3
rep.hpp
src/rep.hpp
+1
-2
req.hpp
src/req.hpp
+2
-4
router.hpp
src/router.hpp
+1
-2
scatter.hpp
src/scatter.hpp
+1
-2
secure_allocator.hpp
src/secure_allocator.hpp
+2
-1
select.hpp
src/select.hpp
+1
-2
server.hpp
src/server.hpp
+1
-2
session_base.hpp
src/session_base.hpp
+1
-2
signaler.hpp
src/signaler.hpp
+3
-4
socket_base.hpp
src/socket_base.hpp
+1
-2
socket_poller.hpp
src/socket_poller.hpp
+1
-2
socks_connecter.hpp
src/socks_connecter.hpp
+1
-2
stream.hpp
src/stream.hpp
+1
-2
stream_connecter_base.hpp
src/stream_connecter_base.hpp
+1
-2
stream_engine_base.hpp
src/stream_engine_base.hpp
+1
-2
stream_listener_base.hpp
src/stream_listener_base.hpp
+1
-3
sub.hpp
src/sub.hpp
+1
-3
tcp_connecter.cpp
src/tcp_connecter.cpp
+2
-2
tcp_connecter.hpp
src/tcp_connecter.hpp
+1
-2
tcp_listener.cpp
src/tcp_listener.cpp
+2
-2
tcp_listener.hpp
src/tcp_listener.hpp
+1
-2
thread.hpp
src/thread.hpp
+1
-2
timers.hpp
src/timers.hpp
+2
-3
tipc_connecter.hpp
src/tipc_connecter.hpp
+1
-2
tipc_listener.hpp
src/tipc_listener.hpp
+1
-2
trie.hpp
src/trie.hpp
+2
-2
v1_decoder.hpp
src/v1_decoder.hpp
+1
-2
v1_encoder.hpp
src/v1_encoder.hpp
+1
-2
v2_decoder.hpp
src/v2_decoder.hpp
+1
-2
v2_encoder.hpp
src/v2_encoder.hpp
+1
-2
vmci_address.hpp
src/vmci_address.hpp
+2
-2
vmci_connecter.hpp
src/vmci_connecter.hpp
+1
-2
vmci_listener.hpp
src/vmci_listener.hpp
+1
-2
ws_connecter.hpp
src/ws_connecter.hpp
+2
-3
ws_decoder.hpp
src/ws_decoder.hpp
+1
-2
ws_encoder.hpp
src/ws_encoder.hpp
+1
-2
ws_listener.hpp
src/ws_listener.hpp
+2
-3
xpub.hpp
src/xpub.hpp
+1
-2
xsub.hpp
src/xsub.hpp
+1
-2
ypipe.hpp
src/ypipe.hpp
+1
-7
ypipe_base.hpp
src/ypipe_base.hpp
+2
-1
ypipe_conflate.hpp
src/ypipe_conflate.hpp
+1
-7
yqueue.hpp
src/yqueue.hpp
+1
-3
zmtp_engine.hpp
src/zmtp_engine.hpp
+1
-2
No files found.
.travis.yml
View file @
9b67fe8a
...
...
@@ -146,7 +146,9 @@ matrix:
before_install
:
-
if [ $TRAVIS_OS_NAME == "osx" -a $BUILD_TYPE == "android" ] ; then brew update; brew install binutils ; fi
-
if [ $TRAVIS_OS_NAME == "osx" -a $CURVE == "libsodium" ] ; then brew update; brew install libsodium ; fi
# To allow sonar to process history information, unshallow clone first.
-
if [ -n "$CLANG_TIDY" ] ; then
git fetch --unshallow ;
curl -L https://sonarcloud.io/static/cpp/build-wrapper-linux-x86.zip -o build-wrapper-linux-x86.zip ;
unzip build-wrapper-linux-x86.zip ;
export SONARCLOUD_BUILD_WRAPPER_PATH="$(pwd)/build-wrapper-linux-x86/" ;
...
...
src/array.hpp
View file @
9b67fe8a
...
...
@@ -33,6 +33,8 @@
#include <vector>
#include <algorithm>
#include "macros.hpp"
namespace
zmq
{
// Implementation of fast arrays with O(1) access, insertion and
...
...
@@ -55,7 +57,7 @@ template <int ID = 0> class array_item_t
// The destructor doesn't have to be virtual. It is made virtual
// just to keep ICC and code checking tools from complaining.
inline
virtual
~
array_item_t
()
{}
inline
virtual
~
array_item_t
()
ZMQ_DEFAULT
;
inline
void
set_array_index
(
int
index_
)
{
_array_index
=
index_
;
}
...
...
@@ -64,8 +66,7 @@ template <int ID = 0> class array_item_t
private
:
int
_array_index
;
array_item_t
(
const
array_item_t
&
);
const
array_item_t
&
operator
=
(
const
array_item_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
array_item_t
)
};
...
...
@@ -77,9 +78,7 @@ template <typename T, int ID = 0> class array_t
public
:
typedef
typename
std
::
vector
<
T
*>::
size_type
size_type
;
inline
array_t
()
{}
inline
~
array_t
()
{}
inline
array_t
()
ZMQ_DEFAULT
;
inline
size_type
size
()
{
return
_items
.
size
();
}
...
...
@@ -127,8 +126,7 @@ template <typename T, int ID = 0> class array_t
typedef
std
::
vector
<
T
*>
items_t
;
items_t
_items
;
array_t
(
const
array_t
&
);
const
array_t
&
operator
=
(
const
array_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
array_t
)
};
}
...
...
src/atomic_counter.hpp
View file @
9b67fe8a
...
...
@@ -214,8 +214,7 @@ class atomic_counter_t
#endif
#if !defined ZMQ_ATOMIC_COUNTER_CXX11
atomic_counter_t
(
const
atomic_counter_t
&
);
const
atomic_counter_t
&
operator
=
(
const
atomic_counter_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
atomic_counter_t
)
#endif
#if defined(__GNUC__) || defined(__INTEL_COMPILER) \
|| (defined(__SUNPRO_C) && __SUNPRO_C >= 0x590) \
...
...
src/atomic_ptr.hpp
View file @
9b67fe8a
...
...
@@ -232,8 +232,7 @@ template <typename T> class atomic_ptr_t
#endif
#if !defined ZMQ_ATOMIC_PTR_CXX11
atomic_ptr_t
(
const
atomic_ptr_t
&
);
const
atomic_ptr_t
&
operator
=
(
const
atomic_ptr_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
atomic_ptr_t
)
#endif
};
...
...
src/client.hpp
View file @
9b67fe8a
...
...
@@ -66,8 +66,7 @@ class client_t : public socket_base_t
fq_t
_fq
;
lb_t
_lb
;
client_t
(
const
client_t
&
);
const
client_t
&
operator
=
(
const
client_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
client_t
)
};
}
...
...
src/clock.hpp
View file @
9b67fe8a
...
...
@@ -30,6 +30,7 @@
#ifndef __ZMQ_CLOCK_HPP_INCLUDED__
#define __ZMQ_CLOCK_HPP_INCLUDED__
#include "macros.hpp"
#include "stdint.hpp"
#if defined ZMQ_HAVE_OSX
...
...
@@ -72,8 +73,7 @@ class clock_t
// Physical time corresponding to the TSC above (in milliseconds).
uint64_t
_last_time
;
clock_t
(
const
clock_t
&
);
const
clock_t
&
operator
=
(
const
clock_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
clock_t
)
};
}
...
...
src/condition_variable.hpp
View file @
9b67fe8a
...
...
@@ -44,8 +44,6 @@ class condition_variable_t
public
:
inline
condition_variable_t
()
{
zmq_assert
(
false
);
}
inline
~
condition_variable_t
()
{}
inline
int
wait
(
mutex_t
*
mutex_
,
int
timeout_
)
{
zmq_assert
(
false
);
...
...
@@ -54,10 +52,7 @@ class condition_variable_t
inline
void
broadcast
()
{
zmq_assert
(
false
);
}
private
:
// Disable copy construction and assignment.
condition_variable_t
(
const
condition_variable_t
&
);
void
operator
=
(
const
condition_variable_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
condition_variable_t
)
};
}
...
...
@@ -72,8 +67,6 @@ class condition_variable_t
public
:
inline
condition_variable_t
()
{
InitializeConditionVariable
(
&
_cv
);
}
inline
~
condition_variable_t
()
{}
inline
int
wait
(
mutex_t
*
mutex_
,
int
timeout_
)
{
int
rc
=
SleepConditionVariableCS
(
&
_cv
,
mutex_
->
get_cs
(),
timeout_
);
...
...
@@ -95,9 +88,7 @@ class condition_variable_t
private
:
CONDITION_VARIABLE
_cv
;
// Disable copy construction and assignment.
condition_variable_t
(
const
condition_variable_t
&
);
void
operator
=
(
const
condition_variable_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
condition_variable_t
)
};
}
...
...
@@ -110,9 +101,7 @@ namespace zmq
class
condition_variable_t
{
public
:
inline
condition_variable_t
()
{}
inline
~
condition_variable_t
()
{}
inline
condition_variable_t
()
ZMQ_DEFAULT
;
inline
int
wait
(
mutex_t
*
mutex_
,
int
timeout_
)
{
...
...
@@ -139,9 +128,7 @@ class condition_variable_t
private
:
std
::
condition_variable_any
_cv
;
// Disable copy construction and assignment.
condition_variable_t
(
const
condition_variable_t
&
);
void
operator
=
(
const
condition_variable_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
condition_variable_t
)
};
}
...
...
@@ -154,7 +141,7 @@ namespace zmq
class
condition_variable_t
{
public
:
inline
condition_variable_t
()
{}
inline
condition_variable_t
()
ZMQ_DEFAULT
;
inline
~
condition_variable_t
()
{
...
...
@@ -224,9 +211,7 @@ class condition_variable_t
mutex_t
_listenersMutex
;
std
::
vector
<
SEM_ID
>
_listeners
;
// Disable copy construction and assignment.
condition_variable_t
(
const
condition_variable_t
&
);
const
condition_variable_t
&
operator
=
(
const
condition_variable_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
condition_variable_t
)
};
}
...
...
@@ -318,9 +303,7 @@ class condition_variable_t
private
:
pthread_cond_t
_cond
;
// Disable copy construction and assignment.
condition_variable_t
(
const
condition_variable_t
&
);
const
condition_variable_t
&
operator
=
(
const
condition_variable_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
condition_variable_t
)
};
}
...
...
src/ctx.hpp
View file @
9b67fe8a
...
...
@@ -241,8 +241,7 @@ class ctx_t : public thread_ctx_t
// Should we use zero copy message decoding in this context?
bool
_zero_copy
;
ctx_t
(
const
ctx_t
&
);
const
ctx_t
&
operator
=
(
const
ctx_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
ctx_t
)
#ifdef HAVE_FORK
// the process that created this context. Used to detect forking.
...
...
src/dbuffer.hpp
View file @
9b67fe8a
...
...
@@ -132,9 +132,7 @@ template <> class dbuffer_t<msg_t>
mutex_t
_sync
;
bool
_has_msg
;
// Disable copying of dbuffer.
dbuffer_t
(
const
dbuffer_t
&
);
const
dbuffer_t
&
operator
=
(
const
dbuffer_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
dbuffer_t
)
};
}
...
...
src/dealer.hpp
View file @
9b67fe8a
...
...
@@ -76,8 +76,7 @@ class dealer_t : public socket_base_t
// if true, send an empty message to every connected router peer
bool
_probe_router
;
dealer_t
(
const
dealer_t
&
);
const
dealer_t
&
operator
=
(
const
dealer_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
dealer_t
)
};
}
...
...
src/decoder.hpp
View file @
9b67fe8a
...
...
@@ -186,8 +186,7 @@ class decoder_base_t : public i_decoder
A
_allocator
;
unsigned
char
*
_buf
;
decoder_base_t
(
const
decoder_base_t
&
);
const
decoder_base_t
&
operator
=
(
const
decoder_base_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
decoder_base_t
)
};
}
...
...
src/decoder_allocators.hpp
View file @
9b67fe8a
...
...
@@ -64,8 +64,7 @@ class c_single_allocator
std
::
size_t
_buf_size
;
unsigned
char
*
_buf
;
c_single_allocator
(
c_single_allocator
const
&
);
c_single_allocator
&
operator
=
(
c_single_allocator
const
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
c_single_allocator
)
};
// This allocator allocates a reference counted buffer which is used by v2_decoder_t
...
...
src/devpoll.hpp
View file @
9b67fe8a
...
...
@@ -90,8 +90,7 @@ class devpoll_t : public worker_poller_base_t
// Pollset manipulation function.
void
devpoll_ctl
(
fd_t
fd_
,
short
events_
);
devpoll_t
(
const
devpoll_t
&
);
const
devpoll_t
&
operator
=
(
const
devpoll_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
devpoll_t
)
};
typedef
devpoll_t
poller_t
;
...
...
src/dgram.hpp
View file @
9b67fe8a
...
...
@@ -67,8 +67,7 @@ class dgram_t : public socket_base_t
// If true, more outgoing message parts are expected.
bool
_more_out
;
dgram_t
(
const
dgram_t
&
);
const
dgram_t
&
operator
=
(
const
dgram_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
dgram_t
)
};
}
...
...
src/dish.hpp
View file @
9b67fe8a
...
...
@@ -87,8 +87,7 @@ class dish_t : public socket_base_t
bool
_has_message
;
msg_t
_message
;
dish_t
(
const
dish_t
&
);
const
dish_t
&
operator
=
(
const
dish_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
dish_t
)
};
class
dish_session_t
:
public
session_base_t
...
...
@@ -115,8 +114,7 @@ class dish_session_t : public session_base_t
msg_t
_group_msg
;
dish_session_t
(
const
dish_session_t
&
);
const
dish_session_t
&
operator
=
(
const
dish_session_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
dish_session_t
)
};
}
...
...
src/dist.hpp
View file @
9b67fe8a
...
...
@@ -33,6 +33,7 @@
#include <vector>
#include "array.hpp"
#include "macros.hpp"
namespace
zmq
{
...
...
@@ -107,8 +108,7 @@ class dist_t
// True if last we are in the middle of a multipart message.
bool
_more
;
dist_t
(
const
dist_t
&
);
const
dist_t
&
operator
=
(
const
dist_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
dist_t
)
};
}
...
...
src/encoder.hpp
View file @
9b67fe8a
...
...
@@ -171,10 +171,9 @@ template <typename T> class encoder_base_t : public i_encoder
const
size_t
_buf_size
;
unsigned
char
*
const
_buf
;
encoder_base_t
(
const
encoder_base_t
&
);
void
operator
=
(
const
encoder_base_t
&
);
msg_t
*
_in_progress
;
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
encoder_base_t
)
};
}
...
...
src/epoll.hpp
View file @
9b67fe8a
...
...
@@ -103,8 +103,7 @@ class epoll_t : public worker_poller_base_t
typedef
std
::
vector
<
poll_entry_t
*>
retired_t
;
retired_t
_retired
;
epoll_t
(
const
epoll_t
&
);
const
epoll_t
&
operator
=
(
const
epoll_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
epoll_t
)
};
typedef
epoll_t
poller_t
;
...
...
src/fq.hpp
View file @
9b67fe8a
...
...
@@ -77,8 +77,7 @@ class fq_t
// there are following parts still waiting in the current pipe.
bool
_more
;
fq_t
(
const
fq_t
&
);
const
fq_t
&
operator
=
(
const
fq_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
fq_t
)
};
}
...
...
src/gather.hpp
View file @
9b67fe8a
...
...
@@ -59,8 +59,7 @@ class gather_t : public socket_base_t
// Fair queueing object for inbound pipes.
fq_t
_fq
;
gather_t
(
const
gather_t
&
);
const
gather_t
&
operator
=
(
const
gather_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
gather_t
)
};
}
...
...
src/generic_mtrie.hpp
View file @
9b67fe8a
...
...
@@ -33,6 +33,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#include <stddef.h>
#include <set>
#include "macros.hpp"
#include "stdint.hpp"
namespace
zmq
...
...
@@ -118,9 +119,7 @@ template <typename T> class generic_mtrie_t
class
generic_mtrie_t
<
value_t
>
**
table
;
}
_next
;
generic_mtrie_t
(
const
generic_mtrie_t
<
value_t
>
&
);
const
generic_mtrie_t
<
value_t
>
&
operator
=
(
const
generic_mtrie_t
<
value_t
>
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
generic_mtrie_t
)
};
}
...
...
src/i_decoder.hpp
View file @
9b67fe8a
...
...
@@ -30,6 +30,7 @@
#ifndef __ZMQ_I_DECODER_HPP_INCLUDED__
#define __ZMQ_I_DECODER_HPP_INCLUDED__
#include "macros.hpp"
#include "stdint.hpp"
namespace
zmq
...
...
@@ -41,7 +42,7 @@ class msg_t;
class
i_decoder
{
public
:
virtual
~
i_decoder
()
{}
virtual
~
i_decoder
()
ZMQ_DEFAULT
;
virtual
void
get_buffer
(
unsigned
char
**
data_
,
size_t
*
size_
)
=
0
;
...
...
src/i_encoder.hpp
View file @
9b67fe8a
...
...
@@ -30,6 +30,7 @@
#ifndef __ZMQ_I_ENCODER_HPP_INCLUDED__
#define __ZMQ_I_ENCODER_HPP_INCLUDED__
#include "macros.hpp"
#include "stdint.hpp"
namespace
zmq
...
...
@@ -41,7 +42,7 @@ class msg_t;
struct
i_encoder
{
virtual
~
i_encoder
()
{}
virtual
~
i_encoder
()
ZMQ_DEFAULT
;
// The function returns a batch of binary data. The data
// are filled to a supplied buffer. If no buffer is supplied (data_
...
...
src/i_engine.hpp
View file @
9b67fe8a
...
...
@@ -31,6 +31,7 @@
#define __ZMQ_I_ENGINE_HPP_INCLUDED__
#include "endpoint.hpp"
#include "macros.hpp"
namespace
zmq
{
...
...
@@ -47,7 +48,7 @@ struct i_engine
timeout_error
};
virtual
~
i_engine
()
{}
virtual
~
i_engine
()
ZMQ_DEFAULT
;
// Plug the engine to the session.
virtual
void
plug
(
zmq
::
io_thread_t
*
io_thread_
,
...
...
src/i_mailbox.hpp
View file @
9b67fe8a
...
...
@@ -30,6 +30,7 @@
#ifndef __ZMQ_I_MAILBOX_HPP_INCLUDED__
#define __ZMQ_I_MAILBOX_HPP_INCLUDED__
#include "macros.hpp"
#include "stdint.hpp"
namespace
zmq
...
...
@@ -39,7 +40,7 @@ namespace zmq
class
i_mailbox
{
public
:
virtual
~
i_mailbox
()
{}
virtual
~
i_mailbox
()
ZMQ_DEFAULT
;
virtual
void
send
(
const
command_t
&
cmd_
)
=
0
;
virtual
int
recv
(
command_t
*
cmd_
,
int
timeout_
)
=
0
;
...
...
src/i_poll_events.hpp
View file @
9b67fe8a
...
...
@@ -30,6 +30,8 @@
#ifndef __ZMQ_I_POLL_EVENTS_HPP_INCLUDED__
#define __ZMQ_I_POLL_EVENTS_HPP_INCLUDED__
#include "macros.hpp"
namespace
zmq
{
// Virtual interface to be exposed by object that want to be notified
...
...
@@ -37,7 +39,7 @@ namespace zmq
struct
i_poll_events
{
virtual
~
i_poll_events
()
{}
virtual
~
i_poll_events
()
ZMQ_DEFAULT
;
// Called by I/O thread when file descriptor is ready for reading.
virtual
void
in_event
()
=
0
;
...
...
src/io_object.hpp
View file @
9b67fe8a
...
...
@@ -76,8 +76,7 @@ class io_object_t : public i_poll_events
private
:
poller_t
*
_poller
;
io_object_t
(
const
io_object_t
&
);
const
io_object_t
&
operator
=
(
const
io_object_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
io_object_t
)
};
}
...
...
src/io_thread.hpp
View file @
9b67fe8a
...
...
@@ -85,8 +85,7 @@ class io_thread_t : public object_t, public i_poll_events
// I/O multiplexing is performed using a poller object.
poller_t
*
_poller
;
io_thread_t
(
const
io_thread_t
&
);
const
io_thread_t
&
operator
=
(
const
io_thread_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
io_thread_t
)
};
}
...
...
src/ipc_address.hpp
View file @
9b67fe8a
...
...
@@ -30,10 +30,10 @@
#ifndef __ZMQ_IPC_ADDRESS_HPP_INCLUDED__
#define __ZMQ_IPC_ADDRESS_HPP_INCLUDED__
#include <string>
#if defined ZMQ_HAVE_IPC
#include <string>
#if defined _MSC_VER
#include <afunix.h>
#else
...
...
@@ -41,6 +41,8 @@
#include <sys/un.h>
#endif
#include "macros.hpp"
namespace
zmq
{
class
ipc_address_t
...
...
@@ -63,8 +65,7 @@ class ipc_address_t
struct
sockaddr_un
_address
;
socklen_t
_addrlen
;
ipc_address_t
(
const
ipc_address_t
&
);
const
ipc_address_t
&
operator
=
(
const
ipc_address_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
ipc_address_t
)
};
}
...
...
src/ipc_connecter.hpp
View file @
9b67fe8a
...
...
@@ -64,8 +64,7 @@ class ipc_connecter_t : public stream_connecter_base_t
// retired_fd if the connection was unsuccessful.
fd_t
connect
();
ipc_connecter_t
(
const
ipc_connecter_t
&
);
const
ipc_connecter_t
&
operator
=
(
const
ipc_connecter_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
ipc_connecter_t
)
};
}
...
...
src/ipc_listener.hpp
View file @
9b67fe8a
...
...
@@ -79,8 +79,7 @@ class ipc_listener_t : public stream_listener_base_t
// Name of the file associated with the UNIX domain address.
std
::
string
_filename
;
ipc_listener_t
(
const
ipc_listener_t
&
);
const
ipc_listener_t
&
operator
=
(
const
ipc_listener_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
ipc_listener_t
)
};
}
...
...
src/kqueue.hpp
View file @
9b67fe8a
...
...
@@ -93,8 +93,7 @@ class kqueue_t : public worker_poller_base_t
typedef
std
::
vector
<
poll_entry_t
*>
retired_t
;
retired_t
retired
;
kqueue_t
(
const
kqueue_t
&
);
const
kqueue_t
&
operator
=
(
const
kqueue_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
kqueue_t
)
#ifdef HAVE_FORK
// the process that created this context. Used to detect forking.
...
...
src/lb.hpp
View file @
9b67fe8a
...
...
@@ -78,8 +78,7 @@ class lb_t
// True if we are dropping current message.
bool
_dropping
;
lb_t
(
const
lb_t
&
);
const
lb_t
&
operator
=
(
const
lb_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
lb_t
)
};
}
...
...
src/macros.hpp
View file @
9b67fe8a
...
...
@@ -19,3 +19,29 @@
#define ZMQ_NOEXCEPT
#endif
#endif
#if !defined ZMQ_DEFAULT
#if defined ZMQ_HAVE_NOEXCEPT
#define ZMQ_DEFAULT = default;
#else
#define ZMQ_DEFAULT \
{ \
}
#endif
#endif
#if !defined ZMQ_NON_COPYABLE_NOR_MOVABLE
#if defined ZMQ_HAVE_NOEXCEPT
#define ZMQ_NON_COPYABLE_NOR_MOVABLE(classname) \
public: \
classname (const classname &) = delete; \
classname &operator= (const classname &) = delete; \
classname (classname &&) = delete; \
classname &operator= (classname &&) = delete;
#else
#define ZMQ_NON_COPYABLE_NOR_MOVABLE(classname) \
private: \
classname (const classname &); \
classname &operator= (const classname &);
#endif
#endif
src/mailbox.hpp
View file @
9b67fe8a
...
...
@@ -79,9 +79,7 @@ class mailbox_t : public i_mailbox
// read commands from it.
bool
_active
;
// Disable copying of mailbox_t object.
mailbox_t
(
const
mailbox_t
&
);
const
mailbox_t
&
operator
=
(
const
mailbox_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
mailbox_t
)
};
}
...
...
src/mailbox_safe.hpp
View file @
9b67fe8a
...
...
@@ -81,9 +81,7 @@ class mailbox_safe_t : public i_mailbox
std
::
vector
<
zmq
::
signaler_t
*>
_signalers
;
// Disable copying of mailbox_t object.
mailbox_safe_t
(
const
mailbox_safe_t
&
);
const
mailbox_safe_t
&
operator
=
(
const
mailbox_safe_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
mailbox_safe_t
)
};
}
...
...
src/metadata.hpp
View file @
9b67fe8a
...
...
@@ -55,14 +55,13 @@ class metadata_t
bool
drop_ref
();
private
:
metadata_t
(
const
metadata_t
&
);
metadata_t
&
operator
=
(
const
metadata_t
&
);
// Reference counter.
atomic_counter_t
_ref_cnt
;
// Dictionary holding metadata.
const
dict_t
_dict
;
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
metadata_t
)
};
}
...
...
src/mutex.hpp
View file @
9b67fe8a
...
...
@@ -31,6 +31,7 @@
#define __ZMQ_MUTEX_HPP_INCLUDED__
#include "err.hpp"
#include "macros.hpp"
// Mutex class encapsulates OS mutex in a platform-independent way.
...
...
@@ -61,9 +62,7 @@ class mutex_t
private
:
CRITICAL_SECTION
_cs
;
// Disable copy construction and assignment.
mutex_t
(
const
mutex_t
&
);
void
operator
=
(
const
mutex_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
mutex_t
)
};
}
...
...
@@ -100,9 +99,7 @@ class mutex_t
private
:
SEM_ID
_semId
;
// Disable copy construction and assignment.
mutex_t
(
const
mutex_t
&
);
const
mutex_t
&
operator
=
(
const
mutex_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
mutex_t
)
};
}
...
...
@@ -164,9 +161,7 @@ class mutex_t
pthread_mutex_t
_mutex
;
pthread_mutexattr_t
_attr
;
// Disable copy construction and assignment.
mutex_t
(
const
mutex_t
&
);
const
mutex_t
&
operator
=
(
const
mutex_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
mutex_t
)
};
}
...
...
@@ -184,9 +179,7 @@ struct scoped_lock_t
private
:
mutex_t
&
_mutex
;
// Disable copy construction and assignment.
scoped_lock_t
(
const
scoped_lock_t
&
);
const
scoped_lock_t
&
operator
=
(
const
scoped_lock_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
scoped_lock_t
)
};
...
...
@@ -207,9 +200,7 @@ struct scoped_optional_lock_t
private
:
mutex_t
*
_mutex
;
// Disable copy construction and assignment.
scoped_optional_lock_t
(
const
scoped_lock_t
&
);
const
scoped_optional_lock_t
&
operator
=
(
const
scoped_lock_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
scoped_optional_lock_t
)
};
}
...
...
src/object.hpp
View file @
9b67fe8a
...
...
@@ -31,8 +31,10 @@
#define __ZMQ_OBJECT_HPP_INCLUDED__
#include <string>
#include "stdint.hpp"
#include "endpoint.hpp"
#include "macros.hpp"
#include "stdint.hpp"
namespace
zmq
{
...
...
@@ -157,8 +159,7 @@ class object_t
void
send_command
(
command_t
&
cmd_
);
object_t
(
const
object_t
&
);
const
object_t
&
operator
=
(
const
object_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
object_t
)
};
}
...
...
src/own.hpp
View file @
9b67fe8a
...
...
@@ -140,8 +140,7 @@ class own_t : public object_t
// Number of events we have to get before we can destroy the object.
int
_term_acks
;
own_t
(
const
own_t
&
);
const
own_t
&
operator
=
(
const
own_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
own_t
)
};
}
...
...
src/pair.hpp
View file @
9b67fe8a
...
...
@@ -64,8 +64,7 @@ class pair_t : public socket_base_t
zmq
::
pipe_t
*
_last_in
;
pair_t
(
const
pair_t
&
);
const
pair_t
&
operator
=
(
const
pair_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
pair_t
)
};
}
...
...
src/pgm_receiver.hpp
View file @
9b67fe8a
...
...
@@ -135,8 +135,7 @@ class pgm_receiver_t : public io_object_t, public i_engine
// Poll handle associated with engine PGM waiting pipe.
handle_t
pipe_handle
;
pgm_receiver_t
(
const
pgm_receiver_t
&
);
const
pgm_receiver_t
&
operator
=
(
const
pgm_receiver_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
pgm_receiver_t
)
};
}
...
...
src/pgm_sender.hpp
View file @
9b67fe8a
...
...
@@ -115,8 +115,7 @@ class pgm_sender_t : public io_object_t, public i_engine
// If zero, there are no data to be sent.
size_t
write_size
;
pgm_sender_t
(
const
pgm_sender_t
&
);
const
pgm_sender_t
&
operator
=
(
const
pgm_sender_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
pgm_sender_t
)
};
}
#endif
...
...
src/pipe.hpp
View file @
9b67fe8a
...
...
@@ -59,7 +59,7 @@ int pipepair (zmq::object_t *parents_[2],
struct
i_pipe_events
{
virtual
~
i_pipe_events
()
{}
virtual
~
i_pipe_events
()
ZMQ_DEFAULT
;
virtual
void
read_activated
(
zmq
::
pipe_t
*
pipe_
)
=
0
;
virtual
void
write_activated
(
zmq
::
pipe_t
*
pipe_
)
=
0
;
...
...
@@ -256,9 +256,7 @@ class pipe_t : public object_t,
// The endpoints of this pipe.
endpoint_uri_pair_t
_endpoint_pair
;
// Disable copying.
pipe_t
(
const
pipe_t
&
);
const
pipe_t
&
operator
=
(
const
pipe_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
pipe_t
)
};
void
send_routing_id
(
pipe_t
*
pipe_
,
const
options_t
&
options_
);
...
...
src/poll.hpp
View file @
9b67fe8a
...
...
@@ -99,8 +99,7 @@ class poll_t : public worker_poller_base_t
// If true, there's at least one retired event source.
bool
retired
;
poll_t
(
const
poll_t
&
);
const
poll_t
&
operator
=
(
const
poll_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
poll_t
)
};
typedef
poll_t
poller_t
;
...
...
src/poller_base.hpp
View file @
9b67fe8a
...
...
@@ -155,8 +155,7 @@ class poller_base_t
// registered.
atomic_counter_t
_load
;
poller_base_t
(
const
poller_base_t
&
);
const
poller_base_t
&
operator
=
(
const
poller_base_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
poller_base_t
)
};
// Base class for a poller with a single worker thread.
...
...
src/polling_util.hpp
View file @
9b67fe8a
...
...
@@ -33,6 +33,7 @@
#include <stdlib.h>
#include <vector>
#include "macros.hpp"
#include "stdint.hpp"
#include "platform.hpp"
#include "err.hpp"
...
...
@@ -62,11 +63,10 @@ template <typename T, size_t S> class fast_vector_t
}
private
:
fast_vector_t
(
const
fast_vector_t
&
);
fast_vector_t
&
operator
=
(
const
fast_vector_t
&
);
T
_static_buf
[
S
];
T
*
_buf
;
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
fast_vector_t
)
};
template
<
typename
T
,
size_t
S
>
class
resizable_fast_vector_t
...
...
@@ -96,11 +96,10 @@ template <typename T, size_t S> class resizable_fast_vector_t
~
resizable_fast_vector_t
()
{
delete
_dynamic_buf
;
}
private
:
resizable_fast_vector_t
(
const
resizable_fast_vector_t
&
);
resizable_fast_vector_t
&
operator
=
(
const
resizable_fast_vector_t
&
);
T
_static_buf
[
S
];
std
::
vector
<
T
>
*
_dynamic_buf
;
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
resizable_fast_vector_t
)
};
#if defined ZMQ_POLL_BASED_ON_POLL
...
...
src/pollset.hpp
View file @
9b67fe8a
...
...
@@ -105,8 +105,7 @@ class pollset_t : public poller_base_t
// Handle of the physical thread doing the I/O work.
thread_t
worker
;
pollset_t
(
const
pollset_t
&
);
const
pollset_t
&
operator
=
(
const
pollset_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
pollset_t
)
};
typedef
pollset_t
poller_t
;
...
...
src/pub.hpp
View file @
9b67fe8a
...
...
@@ -52,9 +52,7 @@ class pub_t : public xpub_t
int
xrecv
(
zmq
::
msg_t
*
msg_
);
bool
xhas_in
();
private
:
pub_t
(
const
pub_t
&
);
const
pub_t
&
operator
=
(
const
pub_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
pub_t
)
};
}
...
...
src/pull.hpp
View file @
9b67fe8a
...
...
@@ -61,8 +61,7 @@ class pull_t : public socket_base_t
// Fair queueing object for inbound pipes.
fq_t
_fq
;
pull_t
(
const
pull_t
&
);
const
pull_t
&
operator
=
(
const
pull_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
pull_t
)
};
}
...
...
src/push.hpp
View file @
9b67fe8a
...
...
@@ -61,8 +61,7 @@ class push_t : public socket_base_t
// Load balancer managing the outbound pipes.
lb_t
_lb
;
push_t
(
const
push_t
&
);
const
push_t
&
operator
=
(
const
push_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
push_t
)
};
}
...
...
src/radio.hpp
View file @
9b67fe8a
...
...
@@ -79,8 +79,7 @@ class radio_t : public socket_base_t
// Drop messages if HWM reached, otherwise return with EAGAIN
bool
_lossy
;
radio_t
(
const
radio_t
&
);
const
radio_t
&
operator
=
(
const
radio_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
radio_t
)
};
class
radio_session_t
:
public
session_base_t
...
...
@@ -107,8 +106,7 @@ class radio_session_t : public session_base_t
msg_t
_pending_msg
;
radio_session_t
(
const
radio_session_t
&
);
const
radio_session_t
&
operator
=
(
const
radio_session_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
radio_session_t
)
};
}
...
...
src/raw_decoder.hpp
View file @
9b67fe8a
...
...
@@ -61,8 +61,7 @@ class raw_decoder_t : public i_decoder
shared_message_memory_allocator
_allocator
;
raw_decoder_t
(
const
raw_decoder_t
&
);
void
operator
=
(
const
raw_decoder_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
raw_decoder_t
)
};
}
...
...
src/raw_encoder.hpp
View file @
9b67fe8a
...
...
@@ -49,8 +49,7 @@ class raw_encoder_t : public encoder_base_t<raw_encoder_t>
private
:
void
raw_message_ready
();
raw_encoder_t
(
const
raw_encoder_t
&
);
const
raw_encoder_t
&
operator
=
(
const
raw_encoder_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
raw_encoder_t
)
};
}
...
...
src/raw_engine.hpp
View file @
9b67fe8a
...
...
@@ -70,8 +70,7 @@ class raw_engine_t : public stream_engine_base_t
private
:
int
push_raw_msg_to_session
(
msg_t
*
msg_
);
raw_engine_t
(
const
raw_engine_t
&
);
const
raw_engine_t
&
operator
=
(
const
raw_engine_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
raw_engine_t
)
};
}
...
...
src/reaper.hpp
View file @
9b67fe8a
...
...
@@ -77,13 +77,12 @@ class reaper_t : public object_t, public i_poll_events
// If true, we were already asked to terminate.
bool
_terminating
;
reaper_t
(
const
reaper_t
&
);
const
reaper_t
&
operator
=
(
const
reaper_t
&
);
#ifdef HAVE_FORK
// the process that created this context. Used to detect forking.
pid_t
_pid
;
#endif
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
reaper_t
)
};
}
...
...
src/rep.hpp
View file @
9b67fe8a
...
...
@@ -60,8 +60,7 @@ class rep_t : public router_t
// of the request is the backtrace stack.
bool
_request_begins
;
rep_t
(
const
rep_t
&
);
const
rep_t
&
operator
=
(
const
rep_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
rep_t
)
};
}
...
...
src/req.hpp
View file @
9b67fe8a
...
...
@@ -83,8 +83,7 @@ class req_t : public dealer_t
// still pending.
bool
_strict
;
req_t
(
const
req_t
&
);
const
req_t
&
operator
=
(
const
req_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
req_t
)
};
class
req_session_t
:
public
session_base_t
...
...
@@ -109,8 +108,7 @@ class req_session_t : public session_base_t
body
}
_state
;
req_session_t
(
const
req_session_t
&
);
const
req_session_t
&
operator
=
(
const
req_session_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
req_session_t
)
};
}
...
...
src/router.hpp
View file @
9b67fe8a
...
...
@@ -123,8 +123,7 @@ class router_t : public routing_socket_base_t
// will be terminated.
bool
_handover
;
router_t
(
const
router_t
&
);
const
router_t
&
operator
=
(
const
router_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
router_t
)
};
}
...
...
src/scatter.hpp
View file @
9b67fe8a
...
...
@@ -61,8 +61,7 @@ class scatter_t : public socket_base_t
// Load balancer managing the outbound pipes.
lb_t
_lb
;
scatter_t
(
const
scatter_t
&
);
const
scatter_t
&
operator
=
(
const
scatter_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
scatter_t
)
};
}
...
...
src/secure_allocator.hpp
View file @
9b67fe8a
...
...
@@ -48,7 +48,8 @@ template <class T> struct secure_allocator_t
{
typedef
T
value_type
;
secure_allocator_t
()
{}
secure_allocator_t
()
ZMQ_DEFAULT
;
template
<
class
U
>
secure_allocator_t
(
const
secure_allocator_t
<
U
>
&
)
ZMQ_NOEXCEPT
{
...
...
src/select.hpp
View file @
9b67fe8a
...
...
@@ -160,8 +160,7 @@ class select_t : public worker_poller_base_t
static
fd_entries_t
::
iterator
find_fd_entry_by_handle
(
fd_entries_t
&
fd_entries_
,
handle_t
handle_
);
select_t
(
const
select_t
&
);
const
select_t
&
operator
=
(
const
select_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
select_t
)
};
typedef
select_t
poller_t
;
...
...
src/server.hpp
View file @
9b67fe8a
...
...
@@ -81,8 +81,7 @@ class server_t : public socket_base_t
// algorithm. This value is the next ID to use (if not used already).
uint32_t
_next_routing_id
;
server_t
(
const
server_t
&
);
const
server_t
&
operator
=
(
const
server_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
server_t
)
};
}
...
...
src/session_base.hpp
View file @
9b67fe8a
...
...
@@ -196,8 +196,7 @@ class session_base_t : public own_t, public io_object_t, public i_pipe_events
// in order to maintain the value at the creation time
char
*
_wss_hostname
;
session_base_t
(
const
session_base_t
&
);
const
session_base_t
&
operator
=
(
const
session_base_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
session_base_t
)
};
}
...
...
src/signaler.hpp
View file @
9b67fe8a
...
...
@@ -35,6 +35,7 @@
#endif
#include "fd.hpp"
#include "macros.hpp"
namespace
zmq
{
...
...
@@ -72,10 +73,6 @@ class signaler_t
fd_t
_w
;
fd_t
_r
;
// Disable copying of signaler_t object.
signaler_t
(
const
signaler_t
&
);
const
signaler_t
&
operator
=
(
const
signaler_t
&
);
#ifdef HAVE_FORK
// the process that created this context. Used to detect forking.
pid_t
pid
;
...
...
@@ -83,6 +80,8 @@ class signaler_t
// and forked().
void
close_internal
();
#endif
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
signaler_t
)
};
}
...
...
src/socket_base.hpp
View file @
9b67fe8a
...
...
@@ -341,8 +341,7 @@ class socket_base_t : public own_t,
// Mutex to synchronize access to the monitor Pair socket
mutex_t
_monitor_sync
;
socket_base_t
(
const
socket_base_t
&
);
const
socket_base_t
&
operator
=
(
const
socket_base_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
socket_base_t
)
};
class
routing_socket_base_t
:
public
socket_base_t
...
...
src/socket_poller.hpp
View file @
9b67fe8a
...
...
@@ -144,8 +144,7 @@ class socket_poller_t
zmq
::
fd_t
_max_fd
;
#endif
socket_poller_t
(
const
socket_poller_t
&
);
const
socket_poller_t
&
operator
=
(
const
socket_poller_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
socket_poller_t
)
};
}
...
...
src/socks_connecter.hpp
View file @
9b67fe8a
...
...
@@ -128,8 +128,7 @@ class socks_connecter_t : public stream_connecter_base_t
int
_status
;
socks_connecter_t
(
const
socks_connecter_t
&
);
const
socks_connecter_t
&
operator
=
(
const
socks_connecter_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
socks_connecter_t
)
};
}
...
...
src/stream.hpp
View file @
9b67fe8a
...
...
@@ -87,8 +87,7 @@ class stream_t : public routing_socket_base_t
// algorithm. This value is the next ID to use (if not used already).
uint32_t
_next_integral_routing_id
;
stream_t
(
const
stream_t
&
);
const
stream_t
&
operator
=
(
const
stream_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
stream_t
)
};
}
...
...
src/stream_connecter_base.hpp
View file @
9b67fe8a
...
...
@@ -117,8 +117,7 @@ class stream_connecter_base_t : public own_t, public io_object_t
// Current reconnect ivl, updated for backoff strategy
int
_current_reconnect_ivl
;
stream_connecter_base_t
(
const
stream_connecter_base_t
&
);
const
stream_connecter_base_t
&
operator
=
(
const
stream_connecter_base_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
stream_connecter_base_t
)
};
}
...
...
src/stream_engine_base.hpp
View file @
9b67fe8a
...
...
@@ -191,8 +191,7 @@ class stream_engine_base_t : public io_object_t, public i_engine
// Socket
zmq
::
socket_base_t
*
_socket
;
stream_engine_base_t
(
const
stream_engine_base_t
&
);
const
stream_engine_base_t
&
operator
=
(
const
stream_engine_base_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
stream_engine_base_t
)
};
}
...
...
src/stream_listener_base.hpp
View file @
9b67fe8a
...
...
@@ -81,9 +81,7 @@ class stream_listener_base_t : public own_t, public io_object_t
// String representation of endpoint to bind to
std
::
string
_endpoint
;
private
:
stream_listener_base_t
(
const
stream_listener_base_t
&
);
const
stream_listener_base_t
&
operator
=
(
const
stream_listener_base_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
stream_listener_base_t
)
};
}
...
...
src/sub.hpp
View file @
9b67fe8a
...
...
@@ -50,9 +50,7 @@ class sub_t : public xsub_t
int
xsend
(
zmq
::
msg_t
*
msg_
);
bool
xhas_out
();
private
:
sub_t
(
const
sub_t
&
);
const
sub_t
&
operator
=
(
const
sub_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
sub_t
)
};
}
...
...
src/tcp_connecter.cpp
View file @
9b67fe8a
...
...
@@ -296,8 +296,8 @@ bool zmq::tcp_connecter_t::tune_socket (const fd_t fd_)
{
const
int
rc
=
tune_tcp_socket
(
fd_
)
|
tune_tcp_keepalives
(
fd_
,
options
.
tcp_keepalive
,
options
.
tcp_keepalive_cnt
,
options
.
tcp_keepalive_idle
,
options
.
tcp_keepalive_intvl
)
fd_
,
options
.
tcp_keepalive
,
options
.
tcp_keepalive_cnt
,
options
.
tcp_keepalive_idle
,
options
.
tcp_keepalive_intvl
)
|
tune_tcp_maxrt
(
fd_
,
options
.
tcp_maxrt
);
return
rc
==
0
;
}
src/tcp_connecter.hpp
View file @
9b67fe8a
...
...
@@ -83,8 +83,7 @@ class tcp_connecter_t : public stream_connecter_base_t
// True iff a timer has been started.
bool
_connect_timer_started
;
tcp_connecter_t
(
const
tcp_connecter_t
&
);
const
tcp_connecter_t
&
operator
=
(
const
tcp_connecter_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
tcp_connecter_t
)
};
}
...
...
src/tcp_listener.cpp
View file @
9b67fe8a
...
...
@@ -81,8 +81,8 @@ void zmq::tcp_listener_t::in_event ()
int
rc
=
tune_tcp_socket
(
fd
);
rc
=
rc
|
tune_tcp_keepalives
(
fd
,
options
.
tcp_keepalive
,
options
.
tcp_keepalive_cnt
,
options
.
tcp_keepalive_idle
,
options
.
tcp_keepalive_intvl
);
fd
,
options
.
tcp_keepalive
,
options
.
tcp_keepalive_cnt
,
options
.
tcp_keepalive_idle
,
options
.
tcp_keepalive_intvl
);
rc
=
rc
|
tune_tcp_maxrt
(
fd
,
options
.
tcp_maxrt
);
if
(
rc
!=
0
)
{
_socket
->
event_accept_failed
(
...
...
src/tcp_listener.hpp
View file @
9b67fe8a
...
...
@@ -64,8 +64,7 @@ class tcp_listener_t : public stream_listener_base_t
// Address to listen on.
tcp_address_t
_address
;
tcp_listener_t
(
const
tcp_listener_t
&
);
const
tcp_listener_t
&
operator
=
(
const
tcp_listener_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
tcp_listener_t
)
};
}
...
...
src/thread.hpp
View file @
9b67fe8a
...
...
@@ -129,8 +129,7 @@ class thread_t
int
_thread_sched_policy
;
std
::
set
<
int
>
_thread_affinity_cpus
;
thread_t
(
const
thread_t
&
);
const
thread_t
&
operator
=
(
const
thread_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
thread_t
)
};
}
...
...
src/timers.hpp
View file @
9b67fe8a
...
...
@@ -99,10 +99,9 @@ class timers_t
typedef
std
::
set
<
int
>
cancelled_timers_t
;
cancelled_timers_t
_cancelled_timers
;
timers_t
(
const
timers_t
&
);
const
timers_t
&
operator
=
(
const
timers_t
&
);
struct
match_by_id
;
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
timers_t
)
};
}
...
...
src/tipc_connecter.hpp
View file @
9b67fe8a
...
...
@@ -66,8 +66,7 @@ class tipc_connecter_t : public stream_connecter_base_t
// EAGAIN errno if async connect was launched.
int
open
();
tipc_connecter_t
(
const
tipc_connecter_t
&
);
const
tipc_connecter_t
&
operator
=
(
const
tipc_connecter_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
tipc_connecter_t
)
};
}
...
...
src/tipc_listener.hpp
View file @
9b67fe8a
...
...
@@ -67,8 +67,7 @@ class tipc_listener_t : public stream_listener_base_t
// Address to listen on
tipc_address_t
_address
;
tipc_listener_t
(
const
tipc_listener_t
&
);
const
tipc_listener_t
&
operator
=
(
const
tipc_listener_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
tipc_listener_t
)
};
}
...
...
src/trie.hpp
View file @
9b67fe8a
...
...
@@ -32,6 +32,7 @@
#include <stddef.h>
#include "macros.hpp"
#include "stdint.hpp"
namespace
zmq
...
...
@@ -77,8 +78,7 @@ class trie_t
class
trie_t
**
table
;
}
_next
;
trie_t
(
const
trie_t
&
);
const
trie_t
&
operator
=
(
const
trie_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
trie_t
)
};
}
...
...
src/v1_decoder.hpp
View file @
9b67fe8a
...
...
@@ -55,8 +55,7 @@ class v1_decoder_t : public decoder_base_t<v1_decoder_t>
const
int64_t
_max_msg_size
;
v1_decoder_t
(
const
v1_decoder_t
&
);
void
operator
=
(
const
v1_decoder_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
v1_decoder_t
)
};
}
...
...
src/v1_encoder.hpp
View file @
9b67fe8a
...
...
@@ -48,8 +48,7 @@ class v1_encoder_t : public encoder_base_t<v1_encoder_t>
unsigned
char
_tmpbuf
[
10
];
v1_encoder_t
(
const
v1_encoder_t
&
);
const
v1_encoder_t
&
operator
=
(
const
v1_encoder_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
v1_encoder_t
)
};
}
...
...
src/v2_decoder.hpp
View file @
9b67fe8a
...
...
@@ -63,8 +63,7 @@ class v2_decoder_t
const
bool
_zero_copy
;
const
int64_t
_max_msg_size
;
v2_decoder_t
(
const
v2_decoder_t
&
);
void
operator
=
(
const
v2_decoder_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
v2_decoder_t
)
};
}
...
...
src/v2_encoder.hpp
View file @
9b67fe8a
...
...
@@ -48,8 +48,7 @@ class v2_encoder_t : public encoder_base_t<v2_encoder_t>
unsigned
char
_tmp_buf
[
9
];
v2_encoder_t
(
const
v2_encoder_t
&
);
const
v2_encoder_t
&
operator
=
(
const
v2_encoder_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
v2_encoder_t
)
};
}
...
...
src/vmci_address.hpp
View file @
9b67fe8a
...
...
@@ -61,8 +61,8 @@ class vmci_address_t
ctx_t
*
parent
;
vmci_address_t
();
vmci_address_t
(
const
vmci_address_t
&
);
const
vmci_address_t
&
operator
=
(
const
vmci_address_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
vmci_address_t
)
};
}
...
...
src/vmci_connecter.hpp
View file @
9b67fe8a
...
...
@@ -128,8 +128,7 @@ class vmci_connecter_t : public own_t, public io_object_t
// Socket
zmq
::
socket_base_t
*
socket
;
vmci_connecter_t
(
const
vmci_connecter_t
&
);
const
vmci_connecter_t
&
operator
=
(
const
vmci_connecter_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
vmci_connecter_t
)
};
}
...
...
src/vmci_listener.hpp
View file @
9b67fe8a
...
...
@@ -89,8 +89,7 @@ class vmci_listener_t : public own_t, public io_object_t
// String representation of endpoint to bind to
std
::
string
endpoint
;
vmci_listener_t
(
const
vmci_listener_t
&
);
const
vmci_listener_t
&
operator
=
(
const
vmci_listener_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
vmci_listener_t
)
};
}
...
...
src/ws_connecter.hpp
View file @
9b67fe8a
...
...
@@ -88,11 +88,10 @@ class ws_connecter_t : public stream_connecter_base_t
// True iff a timer has been started.
bool
_connect_timer_started
;
ws_connecter_t
(
const
ws_connecter_t
&
);
const
ws_connecter_t
&
operator
=
(
const
ws_connecter_t
&
);
bool
_wss
;
const
char
*
_hostname
;
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
ws_connecter_t
)
};
}
...
...
src/ws_decoder.hpp
View file @
9b67fe8a
...
...
@@ -74,8 +74,7 @@ class ws_decoder_t
zmq
::
ws_protocol_t
::
opcode_t
_opcode
;
unsigned
char
_mask
[
4
];
ws_decoder_t
(
const
ws_decoder_t
&
);
void
operator
=
(
const
ws_decoder_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
ws_decoder_t
)
};
}
...
...
src/ws_encoder.hpp
View file @
9b67fe8a
...
...
@@ -51,8 +51,7 @@ class ws_encoder_t : public encoder_base_t<ws_encoder_t>
unsigned
char
_mask
[
4
];
msg_t
_masked_msg
;
ws_encoder_t
(
const
ws_encoder_t
&
);
const
ws_encoder_t
&
operator
=
(
const
ws_encoder_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
ws_encoder_t
)
};
}
...
...
src/ws_listener.hpp
View file @
9b67fe8a
...
...
@@ -72,13 +72,12 @@ class ws_listener_t : public stream_listener_base_t
// Address to listen on.
ws_address_t
_address
;
ws_listener_t
(
const
ws_listener_t
&
);
const
ws_listener_t
&
operator
=
(
const
ws_listener_t
&
);
bool
_wss
;
#if ZMQ_HAVE_WSS
gnutls_certificate_credentials_t
_tls_cred
;
#endif
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
ws_listener_t
)
};
}
...
...
src/xpub.hpp
View file @
9b67fe8a
...
...
@@ -132,8 +132,7 @@ class xpub_t : public socket_base_t
std
::
deque
<
metadata_t
*>
_pending_metadata
;
std
::
deque
<
unsigned
char
>
_pending_flags
;
xpub_t
(
const
xpub_t
&
);
const
xpub_t
&
operator
=
(
const
xpub_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
xpub_t
)
};
}
...
...
src/xsub.hpp
View file @
9b67fe8a
...
...
@@ -111,8 +111,7 @@ class xsub_t : public socket_base_t
// message are treated as user data regardless of the first byte.
bool
_only_first_subscribe
;
xsub_t
(
const
xsub_t
&
);
const
xsub_t
&
operator
=
(
const
xsub_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
xsub_t
)
};
}
...
...
src/ypipe.hpp
View file @
9b67fe8a
...
...
@@ -58,10 +58,6 @@ template <typename T, int N> class ypipe_t : public ypipe_base_t<T>
_c
.
set
(
&
_queue
.
back
());
}
// The destructor doesn't have to be virtual. It is made virtual
// just to keep ICC and code checking tools from complaining.
inline
virtual
~
ypipe_t
()
{}
// Following function (write) deliberately copies uninitialised data
// when used with zmq_msg. Initialising the VSM body for
// non-VSM messages won't be good for performance.
...
...
@@ -202,9 +198,7 @@ template <typename T, int N> class ypipe_t : public ypipe_base_t<T>
// atomic operations.
atomic_ptr_t
<
T
>
_c
;
// Disable copying of ypipe object.
ypipe_t
(
const
ypipe_t
&
);
const
ypipe_t
&
operator
=
(
const
ypipe_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
ypipe_t
)
};
}
...
...
src/ypipe_base.hpp
View file @
9b67fe8a
...
...
@@ -31,6 +31,7 @@
#ifndef __ZMQ_YPIPE_BASE_HPP_INCLUDED__
#define __ZMQ_YPIPE_BASE_HPP_INCLUDED__
#include "macros.hpp"
namespace
zmq
{
...
...
@@ -41,7 +42,7 @@ namespace zmq
template
<
typename
T
>
class
ypipe_base_t
{
public
:
virtual
~
ypipe_base_t
()
{}
virtual
~
ypipe_base_t
()
ZMQ_DEFAULT
;
virtual
void
write
(
const
T
&
value_
,
bool
incomplete_
)
=
0
;
virtual
bool
unwrite
(
T
*
value_
)
=
0
;
virtual
bool
flush
()
=
0
;
...
...
src/ypipe_conflate.hpp
View file @
9b67fe8a
...
...
@@ -49,10 +49,6 @@ template <typename T> class ypipe_conflate_t : public ypipe_base_t<T>
// Initialises the pipe.
inline
ypipe_conflate_t
()
:
reader_awake
(
false
)
{}
// The destructor doesn't have to be virtual. It is made virtual
// just to keep ICC and code checking tools from complaining.
inline
virtual
~
ypipe_conflate_t
()
{}
// Following function (write) deliberately copies uninitialised data
// when used with zmq_msg. Initialising the VSM body for
// non-VSM messages won't be good for performance.
...
...
@@ -110,9 +106,7 @@ template <typename T> class ypipe_conflate_t : public ypipe_base_t<T>
dbuffer_t
<
T
>
dbuffer
;
bool
reader_awake
;
// Disable copying of ypipe object.
ypipe_conflate_t
(
const
ypipe_conflate_t
&
);
const
ypipe_conflate_t
&
operator
=
(
const
ypipe_conflate_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
ypipe_conflate_t
)
};
}
...
...
src/yqueue.hpp
View file @
9b67fe8a
...
...
@@ -207,9 +207,7 @@ template <typename T, int N> class yqueue_t
// us from having to call malloc/free.
atomic_ptr_t
<
chunk_t
>
_spare_chunk
;
// Disable copying of yqueue.
yqueue_t
(
const
yqueue_t
&
);
const
yqueue_t
&
operator
=
(
const
yqueue_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
yqueue_t
)
};
}
...
...
src/zmtp_engine.hpp
View file @
9b67fe8a
...
...
@@ -125,8 +125,7 @@ class zmtp_engine_t : public stream_engine_base_t
int
_heartbeat_timeout
;
zmtp_engine_t
(
const
zmtp_engine_t
&
);
const
zmtp_engine_t
&
operator
=
(
const
zmtp_engine_t
&
);
ZMQ_NON_COPYABLE_NOR_MOVABLE
(
zmtp_engine_t
)
};
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment