summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRoman Mohr <roman@fenkhuber.at>2013-06-23 17:25:50 +0200
committerRoman Mohr <roman@fenkhuber.at>2013-06-23 17:26:43 +0200
commit2b7bccbb42e8826fedd4142cf21d2386c0afb039 (patch)
tree0fef5c0056a97e08a713e965cbf385ec3000e7cf
parent578291641606aa0eaf9d28b125cb634a9ef27540 (diff)
downloadlibjoedog-master.tar.gz
libjoedog-master.tar.xz
libjoedog-master.zip
siege compatibility patchesHEADmaster
-rw-r--r--ChangeLog6
-rw-r--r--include/joedog/defs.h7
-rw-r--r--include/joedog/joedog.h14
3 files changed, 23 insertions, 4 deletions
diff --git a/ChangeLog b/ChangeLog
index a866f1b..49c3990 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,4 +1,8 @@
*libjoedog-0.1.0 (23 Jun 2013)
- 23 Jun 2013; Roman Mohr <roman@fenkhuber.at>:
+ 22 Jun 2013; Roman Mohr <roman@fenkhuber.at>:
initial release based on fido-1.1.0-beta
+
+ 23 Jun 2013; Roman Mohr <roman@fenkhuber.at>:
+ compatibility changes for siege
+
diff --git a/include/joedog/defs.h b/include/joedog/defs.h
index da35665..2b33f2b 100644
--- a/include/joedog/defs.h
+++ b/include/joedog/defs.h
@@ -1,6 +1,6 @@
#ifndef JOEDOG_DEFS_H
#define JOEDOG_DEFS_H
-#define private static
+#define private static
#define public
#include <ctype.h>
@@ -10,9 +10,10 @@
#define ISCOMMENT(x) (x == '#')
#define ISSEPARATOR(x) (('='==(x))||(':'==(x)))
#define ISSPACE(x) isspace((unsigned char)(x))
-#define ISOPERAND(x) ('<'==(x)||'>'==(x)||'='==(x))
+#define ISOPERAND(x) ('<'==(x)||'>'==(x)||'='==(x))
#define ISDIGIT(x) isdigit ((unsigned char)(x))
-#define ISQUOTE(x) (x == '"' || x == '\'')
+#define ISNUMBER(v) (((v) > (char)0x2f) && ((v) < (char)0x3a))
+#define ISQUOTE(x) (x == '"' || x == '\'')
#if STDC_HEADERS
# define TOLOWER(Ch) tolower (Ch)
# define TOUPPER(Ch) toupper (Ch)
diff --git a/include/joedog/joedog.h b/include/joedog/joedog.h
index 5698529..3a80c81 100644
--- a/include/joedog/joedog.h
+++ b/include/joedog/joedog.h
@@ -26,6 +26,15 @@
#include <stdarg.h>
#include <joedog/boolean.h>
+#define BLACK 0
+#define RED 1
+#define GREEN 2
+#define YELLOW 3
+#define BLUE 4
+#define MAGENTA 5
+#define CYAN 6
+#define WHITE 7
+
/**
* Error notification
*/
@@ -42,11 +51,16 @@ void CLOSELOG(void);
void SYSLOG(LEVEL L, const char *fmt, ...);
void NOTIFY(LEVEL L, const char *fmt, ...);
void VERBOSE(BOOLEAN verbose, const char *fmt, ...);
+void DISPLAY(int color, const char *fmt, ...);
+/**
+ * Memory management
+ */
void * xrealloc(void *, size_t);
void * xmalloc (size_t);
void * xcalloc (size_t, size_t);
char * xstrdup(const char *str);
+char * xstrcat(const char *arg1, ...);
void xfree(void *ptr);
/**