[openbeosnetteam] Re: Why does the make environment automatically do a buildclean?

> > All the input functions are declared void, or are supposed to be! I
> > made the
> > change a while back so we actually return void, but if you're
> > bothered then
> > do something else, but don't change the basic behaviour of the server
> > so it
> > doesn't work!
>
> If they are declared void, why is there a return statement? That makes
> no sense. Further, it's an error. Should I just move the statement

If it's an error why is there so much code out there that follows the
pattern? It's an error on metrowerks but the rest of the lunatic asylum that
are compilers don't care.

> above, and then do a void return?

The return is to exit the function.

> > The pr_input definition is in include/sys/protosw.h, where it's been
> > for a
> > while now, and yes, it's a void function. We return the function as
> > it's the
> > end of that part of the routine...
>
> This is an error, and this is what you are doing. Hence, I commented
> out the 3.
> void foo() {
> return 3;
> }
>
> this too:
> void foo() {
> return foo2();
> }
>
> This is not an error:
> void foo() {
> foo2();
> }
>
> Should we restructure it like this?
>
> > How do you expect the server to work with that function commented
> > out??? No
> > IP packets (and you've done it other places as well) will EVER be
> > forwarded
> > to where it's supposed to go and what's more the mbuf will never be
> > freed,
> > so you'll use memory like it's water. Are you sude you got it running
> > before
> > you committed these changes?
>
> OK, uncomment it. I got it *compiling*, as I made non-substantive
> changes to make it compile. I didn't realize that was an important
> function call, the problem was a valued return in a void function. If
> you want, fix it, as I have to go now.
> -Nathan

OK, now how can you call a change that stops the server doing what it's
supposed to "non substantive"????????? In my book that's a big change and
should NOT have been done without asking about it first. Nathan, you could
have saved a LOT of effort over this had you posted patches (as I asked) and
asked about stuff like this that you didn't like. As I've said before there
are no stupid questions, but people who don't ask them tend to fall into the
"stupid" people box.

Yeah OK, I'll go in and fix the errors I guess. I mean why should everyone
else suffer?

david



Other related posts: