* sendto_kdc.c (service_tcp_fd): If DEBUG defined, ensure that
authorEzra Peisach <epeisach@mit.edu>
Tue, 22 Oct 2002 18:56:14 +0000 (18:56 +0000)
committerEzra Peisach <epeisach@mit.edu>
Tue, 22 Oct 2002 18:56:14 +0000 (18:56 +0000)
initialization of variable not bypassed by goto.

git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@14934 dc483132-0cff-0310-8789-dd5450dbe970

src/lib/krb5/os/ChangeLog
src/lib/krb5/os/sendto_kdc.c

index 6c994b1e3037111fd73291a018fc91a4a65f8132..20edb2a409dcae1817ba0a79e5ee176c4eafb931 100644 (file)
@@ -1,3 +1,8 @@
+2002-10-22  Ezra Peisach  <epeisach@bu.edu>
+
+       * sendto_kdc.c (service_tcp_fd): If DEBUG defined, ensure that
+       initialization of variable not bypassed by goto.
+
 2002-10-15  Tom Yu  <tlyu@mit.edu>
 
        * hst_realm.c (krb5_try_realm_txt_rr): Apply patch from Nalin
index 99412546ad4b96f1c5c857423e4db3c5c1bcc489..687f4e0793b0a4fce1b4886b62f650711d529f41 100644 (file)
@@ -708,10 +708,11 @@ service_tcp_fd (struct conn_state *conn, struct select_state *selstate,
        if (ssflags & SSF_EXCEPTION) {
 #ifdef DEBUG
            int sockerr;
-           socklen_t sockerrlen = sizeof(sockerr);
+           socklen_t sockerrlen;
 #endif
        handle_exception:
 #ifdef DEBUG
+           sockerrlen = sizeof(sockerr);
            e = getsockopt(conn->fd, SOL_SOCKET, SO_ERROR,
                           &sockerr, &sockerrlen);
            if (e != 0) {