Browse Source

[core] inline chunkqueue_is_empty()

personal/stbuehler/cleanup-build
Glenn Strauss 4 years ago
parent
commit
f22b5d69da
  1. 4
      src/chunk.c
  2. 5
      src/chunk.h

4
src/chunk.c

@ -694,10 +694,6 @@ off_t chunkqueue_length(chunkqueue *cq) {
return len;
}
int chunkqueue_is_empty(chunkqueue *cq) {
return NULL == cq->first;
}
void chunkqueue_mark_written(chunkqueue *cq, off_t len) {
off_t written = len;
chunk *c;

5
src/chunk.h

@ -98,6 +98,9 @@ off_t chunkqueue_length(chunkqueue *cq);
void chunkqueue_free(chunkqueue *cq);
void chunkqueue_reset(chunkqueue *cq);
int chunkqueue_is_empty(chunkqueue *cq);
static inline int chunkqueue_is_empty(const chunkqueue *cq);
static inline int chunkqueue_is_empty(const chunkqueue *cq) {
return NULL == cq->first;
}
#endif

Loading…
Cancel
Save