Problem with latest OpenSSH - 2.5.2p2

Chris Adams cmadams at hiwaay.net
Sat Apr 14 00:30:27 EST 2001


Once upon a time, Tim Rice <tim at multitalents.net> said:
> >               goto restart_interrupted;
>                 ^^^^^^^^^^^^^
> Even if this works, find another way.
> I don't think goto is portable.

Then how does OpenSSH compile at all?

$ grep -l goto *.[ch]
auth-krb4.c
auth-options.c
auth2.c
authfile.c
buffer.c
dh.c
entropy.c
readconf.c
scp.c
servconf.c
serverloop.c
sftp-client.c
sftp-int.c
ssh-agent.c
ssh-keygen.c
ttymodes.c
$ 

And it looks like every one of them is an actual goto, not a variable
name, comment, or something like that.

Now, goto is not part of official structured programming, but that does
not mean that it is not the best solution to a problem sometimes.
-- 
Chris Adams <cmadams at hiwaay.net>
Systems and Network Administrator - HiWAAY Internet Services
I don't speak for anybody but myself - that's enough trouble.



More information about the openssh-unix-dev mailing list