Walk statcache pathparent

clang found a memory leak, here's a fix
getting path2key to work again in the context of no trailing slashes, and need to treat root directory differently