On 21 January 2013 10:41, Bernhard Reutner-Fischer <[email protected]> wrote: > On 20 January 2013 03:51, Anthony G. Basile <[email protected]> wrote: >> Hi Bernhard, >> >> Following your "statfs: support f_frsize" commit a couple of days ago, >> statvfs is broken. Here's a little poc: >> >> #include <sys/statvfs.h> >> int main() { >> struct statvfs mystat; >> statvfs("/usr/portage/distfiles", &mystat); >> return 0; >> } >> >> which dies with >> >> *** stack smashing detected ***: ./poc terminated >> Killed >> >> Looks like buf->__f_spare is not getting properly zeroed at line 48 of >> libc/misc/statfs/internal_statvfs.c. Reverting to 6 ints fixes it: > > except that the struct is 5 nowadays, not 6. I'll play with the alignment..
It helps if one uses the correct field (and reference..). Fixed on master, thanks! _______________________________________________ uClibc mailing list [email protected] http://lists.busybox.net/mailman/listinfo/uclibc
