version 1.1.1.1, 2012/02/21 17:26:12
|
version 1.1.1.2, 2012/10/09 09:22:28
|
Line 52
|
Line 52
|
* using stream_put..._at() functions. |
* using stream_put..._at() functions. |
*/ |
*/ |
#define STREAM_WARN_OFFSETS(S) \ |
#define STREAM_WARN_OFFSETS(S) \ |
zlog_warn ("&(struct stream): %p, size: %lu, endp: %lu, getp: %lu\n", \ | zlog_warn ("&(struct stream): %p, size: %lu, getp: %lu, endp: %lu\n", \ |
(S), \ |
(S), \ |
(unsigned long) (S)->size, \ |
(unsigned long) (S)->size, \ |
(unsigned long) (S)->getp, \ |
(unsigned long) (S)->getp, \ |
Line 214 stream_set_getp (struct stream *s, size_t pos)
|
Line 214 stream_set_getp (struct stream *s, size_t pos)
|
s->getp = pos; |
s->getp = pos; |
} |
} |
|
|
|
void |
|
stream_set_endp (struct stream *s, size_t pos) |
|
{ |
|
STREAM_VERIFY_SANE(s); |
|
|
|
if (!GETP_VALID (s, pos)) |
|
{ |
|
STREAM_BOUND_WARN (s, "set endp"); |
|
pos = s->endp; |
|
} |
|
|
|
s->endp = pos; |
|
} |
|
|
/* Forward pointer. */ |
/* Forward pointer. */ |
void |
void |
stream_forward_getp (struct stream *s, size_t size) |
stream_forward_getp (struct stream *s, size_t size) |
Line 934 stream_fifo_pop (struct stream_fifo *fifo)
|
Line 948 stream_fifo_pop (struct stream_fifo *fifo)
|
|
|
if (fifo->head == NULL) |
if (fifo->head == NULL) |
fifo->tail = NULL; |
fifo->tail = NULL; |
} |
|
|
|
fifo->count--; | fifo->count--; |
| } |
|
|
return s; |
return s; |
} |
} |