lunixbochs / usercorn

dynamic binary analysis via platform emulation
MIT License
890 stars 98 forks source link

arm linux getdents is incorrect #164

Open lunixbochs opened 8 years ago

lunixbochs commented 8 years ago

might be wrong, a quick trace showed getdents wasn't even called, just an lstat(".")

MagaTailor commented 8 years ago

You're right of course - the displayed dot is coloured red which means there're some garbage terminal codes?

I've just noticed the working (x86_64) ls -a doesn't display the . and .. entries.

lunixbochs commented 8 years ago

Oh, I need to manually add . and .. - opened #170

lunixbochs commented 8 years ago

This might be the problem :) https://github.com/lunixbochs/usercorn/blob/master/go/kernel/posix/stat.go#L16

Edit: yeah, at minimum arm seems to have an early padding section https://bochs.info/p/fzuq8