summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYorhel <git@yorhel.nl>2013-01-15 13:11:31 +0100
committerYorhel <git@yorhel.nl>2013-01-15 13:11:31 +0100
commitc02a338cae7f1cc24d65a613c060017d03d1bd8e (patch)
treef612a968f95b71f4001bc3c38a955c3642dee300
parent73e31340165a9aaeeaeaa76d523c6868a46c9b59 (diff)
ecbuf: Forgot to actually implement ecbuf_popp()
-rw-r--r--ecbuf.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/ecbuf.h b/ecbuf.h
index 6c0eacf..a6b9498 100644
--- a/ecbuf.h
+++ b/ecbuf.h
@@ -189,7 +189,9 @@ static inline int ecbuf__pop(ecbuf_vars_t *v) {
v->o++;
return l;
}
-#define ecbuf_pop(e) ((e).a[ecbuf__pop(&(e).v)])
+
+#define ecbuf_popp(e) ((e).a + ecbuf__pop(&(e).v))
+#define ecbuf_pop(e) (*ecbuf_popp(e))
#endif