[M3devel] rmrec problems

Jay K jay.krell at cornell.edu
Tue Aug 3 11:36:53 CEST 2010


There seems to another final problem, or maybe this was the problem all along, or maybe maybe I introduced this with the previous fix (*)
stat on a symlink whose target has been deleted, apparently fails.
e.g. m3cc/target/gmp/.libs/libgmp.la -> ../libgmp.la


*: maybe I introduced it: Well, before it might have been sensitive to directory enumeration order.
My change deletes files and then subdirectories, making it no longer sensitive that way.

Fix will be to use lstat I believe.

And I'll just report symlinks to be regular files.

And opening them can fail with file not found... which I'm sure will break something somewhere -- enumerated files no longer necessarily exist...

Probably no win.

Probably the original interfaces didn't consider symlinks, since they aren't portable.
Yet without considering them, and composing rmrec on lower level suppostedly portable interfaces..you can't ignore them.
Can't win.


 - Jay
 		 	   		  


More information about the M3devel mailing list