Oliver wrote:
> ok, usually, I ran the program and supply directory name "." as
> current, that doesn't generate any warning message. However, if I
> supply a full path, say "C;\temp", these are the error messages on the
> console. This happen as soon as I put in "require win32/file"

<snip>

These are warnins not errors.  They are harmless - I redefine a bunch
of methods in the File class.

> C:\temp
> c:/ruby/lib/ruby/gems/1.8/gems/win32-file-stat-1.2.2-mswin32/lib/win32/file/stat.rb:263:
> warning: instance v
> iable @directory not initialized

This one is strange, since @directory *is* initialized. But, I doubt
it's the source of your problem

None of this helps me, however.  You still haven't told me exactly what
line specifically is failing.  With or without win32/file, you are
going to get nil for File.size?("C:\\temp") or File.size?("."), since
they are directories.  It must be something else.

- Dan