StackOverflowError from FileRecord.readData when attribute list points to parent record
Project: | JNode FS |
Component: | Code |
Category: | bug report |
Priority: | normal |
Assigned: | Daniel Noll |
Status: | closed |
Description
We have found 4 disks where the attribute list points back into the current record for some attribute entries.
I'm working on a fix but as usual can't provide any sample data for unit testing.
It should also fix something else I noticed, which is that if there are multiple attribute lists stored outside the record and an error occurs on the first one, the rest won't be looked at. Well, this one is minor in comparison.
- Login to post comments
#1
Attached patch fixes this problem and the subsequent problem I discovered in the same area after fixing it (although it seems this one was caused by a disk which some other software also found to be bad, it _did_ cause an infinite loop in this case so it was worth fixing anyway.)
Hopefully this patch is okay... admittedly I generated it from our vendor branch instead of the clean trunk, so let me know if there is an issue and I'll update trunk and re-merge. But I figure there hasn't been much action on this fs driver lately so it will probably be okay.
#2
#3
I've tried to apply the patch but it was rejected.
One reason might be that the code was reformatted in the meantime.
It would be best if you updated your custom sources too and resubmitted a valid patch.
Thank you.
#4
Hey Daniel, I tried to apply your patch with "ignore-whitespaces" but trunk changed already too much. It might be even possible that parts of it already are in trunk.
Could you check and resubmit your patch?
#5
Looks like it's no longer needed. This chunk of code in trunk is the equivalent: