Fix for windows root path

Checking for '/' as root path will not work in windows so it just
spirals out of control and errors when it hits Max nesting (100 on my
machine).