| 768 | } |
| 769 | |
| 770 | void* defragStreamConsumer(raxIterator *ri, void *privdata, long *defragged) { |
| 771 | streamConsumer *c = (streamConsumer*)ri->data; |
| 772 | streamCG *cg = (streamCG*)privdata; |
| 773 | void *newc = activeDefragAlloc(c); |
| 774 | if (newc) { |
| 775 | /* note: we don't increment 'defragged' that's done by the caller */ |
| 776 | c = (streamConsumer*)newc; |
| 777 | } |
| 778 | sds newsds = activeDefragSds(c->name); |
| 779 | if (newsds) |
| 780 | (*defragged)++, c->name = newsds; |
| 781 | if (c->pel) { |
| 782 | PendingEntryContext pel_ctx = {cg, c}; |
| 783 | *defragged += defragRadixTree(&c->pel, 0, defragStreamConsumerPendingEntry, &pel_ctx); |
| 784 | } |
| 785 | return newc; /* returns NULL if c was not defragged */ |
| 786 | } |
| 787 | |
| 788 | void* defragStreamConsumerGroup(raxIterator *ri, void *privdata, long *defragged) { |
| 789 | streamCG *cg = (streamCG*)ri->data; |
nothing calls this directly
no test coverage detected