summaryrefslogtreecommitdiffstats
path: root/lib/elstring.h
diff options
context:
space:
mode:
authorChris Hall <chris.hall@highwayman.com>2011-03-31 00:37:47 +0100
committerChris Hall <chris.hall@highwayman.com>2011-03-31 00:37:47 +0100
commit9a9466f1fdad6fb6c94c5ef8ddb1a687a7bcd874 (patch)
treec4ae426872560a5e070f2054072607f2578e1f7d /lib/elstring.h
parentf3255d1e9f062e7783b05ab5b32ca70085170d79 (diff)
downloadquagga-9a9466f1fdad6fb6c94c5ef8ddb1a687a7bcd874.tar.bz2
quagga-9a9466f1fdad6fb6c94c5ef8ddb1a687a7bcd874.tar.xz
Small improvements to speed of reading of configuration file.
Tidy up signalling of "ready" to command loop, and checking of appropriate state to close written configuration file.
Diffstat (limited to 'lib/elstring.h')
-rw-r--r--lib/elstring.h10
1 files changed, 5 insertions, 5 deletions
diff --git a/lib/elstring.h b/lib/elstring.h
index 8ab1c58d..2b8e77fc 100644
--- a/lib/elstring.h
+++ b/lib/elstring.h
@@ -52,10 +52,9 @@ typedef struct elstring* elstring ;
/* Setting an elstring object to all zeros is enough to initialise it to
* an empty string.
*/
-enum
-{
- ELSTRING_INIT_ALL_ZEROS = true
-} ;
+enum { ELSTRING_INIT_ALL_ZEROS = true } ;
+
+#define ELSTRING_INIT { { { NULL }, 0 } }
/*==============================================================================
* Pointer pair and unsigned pointer pair and const versions.
@@ -177,7 +176,8 @@ extern elstring els_new(void) ;
extern elstring els_free(elstring els) ;
extern int els_cmp(elstring a, elstring b) ;
-extern int els_cmp_word(elstring a, const char* w) ;
+extern int els_nn_cmp(const void* ap, ulen al, const void* bp, ulen bl) ;
+extern int els_cmp_word(elstring a, elstring w) ;
extern int els_cmp_sig(elstring a, elstring b) ;
extern bool els_equal(elstring a, elstring b) ;
extern bool els_substring(elstring a, elstring b) ;