Opening a named pipe now blocks.

Lots of minor changes to support this over last few nights - mainly
around the registry and hashmaps. Looks like there may be lots of weird
memory issues that need to be ironed out as we free up memory and assume
that the freed memory stays the same (it used to but doesn't with
dlmalloc).