Mercurial > hg > libxtract
comparison src/c-ringbuf/ringbuf.c @ 279:6ee836d79500
Add missing MIN() macro define
author | Jamie Bullock <jamie@jamiebullock.com> |
---|---|
date | Fri, 19 Dec 2014 17:46:10 +0000 |
parents | dee3b3f352ed |
children | 730dfd7d613d |
comparison
equal
deleted
inserted
replaced
278:0dbd0078d1c4 | 279:6ee836d79500 |
---|---|
22 #include <sys/uio.h> | 22 #include <sys/uio.h> |
23 #include <unistd.h> | 23 #include <unistd.h> |
24 #include <sys/param.h> | 24 #include <sys/param.h> |
25 #include <assert.h> | 25 #include <assert.h> |
26 | 26 |
27 #ifndef MIN | |
28 #define MIN(x,y) ((x)>(y)?(y):(x)) | |
29 #endif | |
30 | |
27 /* | 31 /* |
28 * The code is written for clarity, not cleverness or performance, and | 32 * The code is written for clarity, not cleverness or performance, and |
29 * contains many assert()s to enforce invariant assumptions and catch | 33 * contains many assert()s to enforce invariant assumptions and catch |
30 * bugs. Feel free to optimize the code and to remove asserts for use | 34 * bugs. Feel free to optimize the code and to remove asserts for use |
31 * in your own projects, once you're comfortable that it functions as | 35 * in your own projects, once you're comfortable that it functions as |