Fix path handling to detect type and size
Merge pull request #8 from lissyx/fix-paths

Fix path handling to detect type and size