I've struggled over some condition making octstr_imm stumble,
this check keeps it from segfaulting.
sincerely,
Wilfried Goesgens
gwlib/octstr.c 2005-04-13 18:13:38.000000000 +0200
+++ octstr.c 2005-04-13 18:49:03.000000000 +0200
@@ -285,7 +285,7 @@ Octstr *octstr_imm(const char *cstr)
mutex_lock(&immutables_mutex);
i = index;
for (; ; ) {
- if (immutables[i] == NULL || immutables[i]->data == data)
+ if (immutables == NULL || immutables[i] == NULL || immutables[i]->data
== data)
break;
i = (i + 1) % MAX_IMMUTABLES;
if (i == index)