Documentation of filelib:ensure_dir in R9C

Björn Bylander bjorn@REDACTED
Sat Jul 3 14:20:13 CEST 2004


Hi,

http://www.erlang.org/doc/r9c/lib/stdlib-1.12/doc/html/filelib.html says ensure_dir/1 always returns true. That's not what I observe with R9C (emulator v5.3) under Linux though:

filelib:ensure_dir("foo") returns true without creating a any directories.
filelib:ensure_dir("foo/bar/baz") returns ok and also creates foo and foo/bar.
filelib:ensure_dir("foo/") returns ok and also creates foo.

I guess filelib:ensure_dir("foo") ensures that "./" exists but the other variants returning ok is not according to the docs as far as I can see...

I get the same behaviour under Windows 2000 and R9C-0.

/Björn



More information about the erlang-questions mailing list