mirror of
https://github.com/zeromq/libzmq.git
synced 2025-10-14 23:07:59 +02:00
Problem: unnecessary non-const variables
Solution: add const
This commit is contained in:
@@ -89,7 +89,8 @@ void zmq::xpub_t::xread_activated (pipe_t *pipe_)
|
||||
msg_t sub;
|
||||
while (pipe_->read (&sub)) {
|
||||
// Apply the subscription to the trie
|
||||
unsigned char *const data = static_cast<unsigned char *> (sub.data ());
|
||||
const unsigned char *const data =
|
||||
static_cast<const unsigned char *> (sub.data ());
|
||||
const size_t size = sub.size ();
|
||||
metadata_t *metadata = sub.metadata ();
|
||||
if (size > 0 && (*data == 0 || *data == 1)) {
|
||||
|
Reference in New Issue
Block a user