Show More
@@ -567,7 +567,7 b' class Session(Configurable):' | |||||
567 | to_send = self.serialize(msg, ident) |
|
567 | to_send = self.serialize(msg, ident) | |
568 | to_send.extend(buffers) |
|
568 | to_send.extend(buffers) | |
569 | longest = max([ len(s) for s in to_send ]) |
|
569 | longest = max([ len(s) for s in to_send ]) | |
570 |
copy = (longest |
|
570 | copy = (longest < self.copy_threshold) | |
571 |
|
571 | |||
572 | if buffers and track and not copy: |
|
572 | if buffers and track and not copy: | |
573 | # only really track when we are doing zero-copy buffers |
|
573 | # only really track when we are doing zero-copy buffers |
@@ -146,6 +146,7 b' class TestSession(SessionTestCase):' | |||||
146 | """test tracking messages""" |
|
146 | """test tracking messages""" | |
147 | a,b = self.create_bound_pair(zmq.PAIR, zmq.PAIR) |
|
147 | a,b = self.create_bound_pair(zmq.PAIR, zmq.PAIR) | |
148 | s = self.session |
|
148 | s = self.session | |
|
149 | s.copy_threshold = 1 | |||
149 | stream = ZMQStream(a) |
|
150 | stream = ZMQStream(a) | |
150 | msg = s.send(a, 'hello', track=False) |
|
151 | msg = s.send(a, 'hello', track=False) | |
151 | self.assertTrue(msg['tracker'] is None) |
|
152 | self.assertTrue(msg['tracker'] is None) |
General Comments 0
You need to be logged in to leave comments.
Login now