port filesystem
add trailing /
strdup return val and update test case
use mkdir
don't free retval
log errors
Merge pull request #5 from gsathya/filesystem

port filesystem