Hell Charles, On Thu, Dec 03, 2009 at 12:00:07PM +0000, Charles Manning wrote: > > Hi Chris > > (Sorry about calling you David) > No worries! > I have just committed a change for the symlink hanging pointer issue you > raised. It is a bit more verbose than yours but I think it does the right > thing. I shall be testing it more and running Valgrind testing too. > > http://www.aleph1.co.uk/cgi-bin/viewcvs.cgi/yaffs2/yaffs_guts.c?r1=1.95&r2=1.96 > > -- Charles > I just sent in two patches. I like the shortest one the best. The above patch does not handle the case where a bogus value makes it into a symlink on the NAND flash. Both of the patches I submitted handle this case. In other words, if someone's filesystem is has an empty alias, like the one I have, mounting will fail. But if one of the patches I supplied is used, then the empty alias is ignored, and mounting will succeed. In our case, if mounting fails bacause of a bunk deleted alias, we would like to simply upgrade the software, and then the existing filesystem mounts and everything is back as it should be. If the case where a bogus value makes it into a symlink on the NAND flash, then the only option is to reformat the YAFFS2 filesystem, and this would lose data. So anyways, my first choice would be for the patch yaffs_guts.c?r1=1.95&r2=1.96 to be reversed, and my short one put in its place. My second choice would be for you or I to add the code necessary to handle the case where a bogus value makes it into a symlink on the NAND flash on top of yaffs_guts.c?r1.96. Please let me know if you would like me to code this. Thanks, -Chris