equal
deleted
inserted
replaced
222 |
222 |
223 |
223 |
224 /* |
224 /* |
225 * NetworkBufferInput template method implementation |
225 * NetworkBufferInput template method implementation |
226 */ |
226 */ |
227 template <typename PrefixType> bool NetworkBufferOutput::peek_data (PrefixType &prefix, char *&buf_ref) { |
227 template <typename PrefixType> bool NetworkBufferInput::peek_data (PrefixType &prefix, char *&buf_ref) { |
228 size_t missing = 0; |
228 size_t missing = 0; |
229 |
229 |
230 do { |
230 do { |
231 // do we have the prefix? |
231 // do we have the prefix? |
232 if (peek_prefix(prefix)) { |
232 if (peek_prefix(prefix)) { |
259 |
259 |
260 // return message |
260 // return message |
261 return true; |
261 return true; |
262 } |
262 } |
263 |
263 |
264 template <typename PrefixType> void NetworkBufferOutput::flush_data (void) { |
264 template <typename PrefixType> void NetworkBufferInput::flush_data (void) { |
265 PrefixType prefix; |
265 PrefixType prefix; |
266 |
266 |
267 // we *must* have a valid prefix |
267 // we *must* have a valid prefix |
268 if (!peek_prefix(prefix)) |
268 if (!peek_prefix(prefix)) |
269 assert(false); |
269 assert(false); |