return (res!=0
? res
- : (nodekey[d->len]=='\0' ? 0 : 1));
+ : (nodekey[d->len]=='\0' ? 0 : -1));
}
StringId stringstore_alloc(const char *str)
{
+ if(str==NULL)
+ return STRINGID_NONE;
+
return stringstore_alloc_n(str, strlen(str));
}
{
Rb_node node=(Rb_node)id;
- if(node==NULL){
- warn("Attempt to free un-allocated string from stringstore.");
+ if(node==NULL)
return;
- }
if(node->v.ival<=0){
warn("Stringstore reference count corrupted.");