Dear Simon, In message <CAPnjgZ15jrh=-tej-0tfjwbszyq+0bihkjlejg3d43wqoow...@mail.gmail.com> you wrote: > > > If this happens, I consider it a bug that should be fixed, and not > > papered over. > > If you look at the code for the 'md' command it calls ctrlc() every > now and then. Each call results in a getc() which reads a character > from the console. So we lose characters.
Well, as I mentioned: it looks like a bug that needs fixing. > > I dislike this idea. It looks wrong to me. Can we not fix the problem > > at the root cause? > > I certainly thought about this. I even though maybe we might change > the serial module to scan ahead and buffer characters, in case there > is a Ctrl-C in the future. But that itself seems like something for > the future. well, I see two sides of this: 1) Looking at sandbox only, we should provide an implementation of ctrlc() that does not consume characters from stdin - I thinkwe should rather be able to react on signals? 2) With a general point of view, consuming characters for no good is always wrong and needs to be fixed. Best regards, Wolfgang Denk -- DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: w...@denx.de Our business is run on trust. We trust you will pay in advance. _______________________________________________ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot