added streq() macro and defined default BUF_LEN

This commit is contained in:
Andreas Steffen 2006-05-24 07:54:20 +00:00
parent 4df5f60bd3
commit 77ad0fa043
1 changed files with 11 additions and 2 deletions

View File

@ -59,16 +59,25 @@
#error "BYTE_ORDER must be defined"
#endif
/**
* Default length for various auxiliary text buffers
*/
#define BUF_LEN 512
/**
* Macro compares to strings for equality
*/
#define streq(x,y) (strcmp(x, y) == 0)
/**
* Macro gives back larger of two values.
*/
#define max(x,y) (x > y ? x : y)
#define max(x,y) ((x) > (y) ? (x):(y))
/**
* Macro gives back smaller of two values.
*/
#define min(x,y) (x < y ? x : y)
#define min(x,y) ((x) < (y) ? (x):(y))
/**
* Debug macro to follow control flow