turns out that there are a few more bad savestr calls even inside of pch.c.
Some of the code pathes are quite obvious that a NULL return value would
lead to a null pointer dereference, others would last longer before
Carefully reviewing the savestr calls, the rule of thumb seems to be:
If savestr is used, immediately check out_of_mem, otherwise use xstrdup.
Theo pointed out that this one is very ugly (indeed):
+ if (!s)
+ s = "Oops";
Yet it's current behavior of savestr. I want to remove that in another
commit. So for now, xstrdup behaves like savestr, calling fatal in case
of out of memory situation -- regardless of "plan a" or "plan b".