Yeah, my fault. Sorry. I should just make the mmap() failure fail gracefully and not provide that part of the elf information. Lemme make a stab at that...
Rob On 05/25/2018 12:30 AM, enh wrote: > ping? > On Mon, May 7, 2018 at 1:35 PM Rob Landley <r...@landley.net> wrote: > >> I got distracted over the weekend, but lemme see if I can come up with a > more >> elegant solution this evening before falling back to that plan. > >> Thanks, > >> Rob > >> On 05/07/2018 01:50 PM, enh wrote: >>> testing with `cat boot.img | strace file -` it looks like FSF >>> allocates a ~10MiB buffer and reads it all in. (rather than copying to >>> a temporary file.) >>> >>> happy to supply that patch instead if you prefer? >>> >>> On Sat, May 5, 2018 at 4:45 PM, Rob Landley <r...@landley.net> wrote: >>>> On 05/05/2018 06:19 PM, enh wrote: >>>>> AFK, but I'm using glibc too, from Debian testing. >>>> >>>> I found it, the stdin case is using the stat.length value to see how > much to >>>> read but never did the stat, so it's uninitialized stack crap. When > it's zero... >>>> >>>> Oops. Oddly enough, the compiler did not complain! >>>> >>>> Needs a design tweak to figure out what the length _should_ be in this > case. >>>> Maybe that read-into-memory suggestion with like a 256k cap or > something? >>>> Working on it... >>>> >>>> Rob >>> > _______________________________________________ Toybox mailing list Toybox@lists.landley.net http://lists.landley.net/listinfo.cgi/toybox-landley.net