On Fri, 2013-02-15 at 00:58 +0100, Samuel Thibault wrote: > Svante Signell, le Fri 15 Feb 2013 00:37:39 +0100, a écrit : > > > No, it doesn't. There are quite a few ways in which it will break. > > > > Well (as you say) I'm a newbie C programmer, tell me where the bugs > > are ;-) > > As I already said, there are too many than I want to even spend time > describing any. > > Be it just > > if (ispoll) > { > case EPIPE:
Yes, that was a mistake, it should be the other way around. > which is obviously bogus without looking at the context. It's sad that > the C compiler can't tell you it does not make sense (I see what sense > you tried to tell the compiler, but sorry that can't work that way). > > if (d[i].io_port == MACH_PORT_NULL) > { > _hurd_port_free (&d[i].cell->port, > > Doesn't make sense either. You haven't understood what the original code > was doing (cleaning the previously allocated ports, not this newly one). I think I did understand what the original code did, but this seemed to be wrongly implemented. Something you could have told me if you had taken the time to do a review. > There are other such kind of issues I don't even want to take time to > look out again. I'll find them myself then. In order learn to write "correct" code. Factorised, hierarchical or something else. The mail has an RFC in the title. I did not claim that the rewrite was completed, did I?