summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorToomas Soome <tsoome@me.com>2017-02-16 00:25:11 +0200
committerGordon Ross <gwr@nexenta.com>2017-05-14 14:23:22 -0400
commit49bf4c2bcfc59b4113c3b5ac2986baee668a1319 (patch)
tree5890db65345a79cf63a0637f013c276c38397228
parent10243bb069053a813aa803c1bbd2620ef4f0deab (diff)
downloadillumos-joyent-49bf4c2bcfc59b4113c3b5ac2986baee668a1319.tar.gz
8219 mech_krb5: misleading-indentation
Reviewed by: Yuri Pankov <yuri.pankov@gmail.com> Reviewed by: Igor Kozhukhov <igor@dilos.org> Reviewed by: Richard Lowe <richlowe@richlowe.net> Approved by: Gordon Ross <gordon.w.ross@gmail.com>
-rw-r--r--usr/src/lib/gss_mechs/mech_krb5/krb5/krb/sendauth.c17
-rw-r--r--usr/src/lib/gss_mechs/mech_krb5/krb5/os/sendto_kdc.c2
2 files changed, 10 insertions, 9 deletions
diff --git a/usr/src/lib/gss_mechs/mech_krb5/krb5/krb/sendauth.c b/usr/src/lib/gss_mechs/mech_krb5/krb5/krb/sendauth.c
index ef3324a9d2..433f7191de 100644
--- a/usr/src/lib/gss_mechs/mech_krb5/krb5/krb/sendauth.c
+++ b/usr/src/lib/gss_mechs/mech_krb5/krb5/krb/sendauth.c
@@ -77,14 +77,15 @@ krb5_sendauth(krb5_context context, krb5_auth_context *auth_context, krb5_pointe
* Now, read back a byte: 0 means no error, 1 means bad sendauth
* version, 2 means bad application version
*/
- if ((len = krb5_net_read(context, *((int *) fd), (char *)&result, 1)) != 1)
- return((len < 0) ? errno : ECONNABORTED);
- if (result == 1)
- return(KRB5_SENDAUTH_BADAUTHVERS);
- else if (result == 2)
- return(KRB5_SENDAUTH_BADAPPLVERS);
- else if (result != 0)
- return(KRB5_SENDAUTH_BADRESPONSE);
+ len = krb5_net_read(context, *((int *) fd), (char *)&result, 1);
+ if (len != 1)
+ return((len < 0) ? errno : ECONNABORTED);
+ if (result == 1)
+ return(KRB5_SENDAUTH_BADAUTHVERS);
+ else if (result == 2)
+ return(KRB5_SENDAUTH_BADAPPLVERS);
+ else if (result != 0)
+ return(KRB5_SENDAUTH_BADRESPONSE);
/*
* We're finished with the initial negotiations; let's get and
* send over the authentication header. (The AP_REQ message)
diff --git a/usr/src/lib/gss_mechs/mech_krb5/krb5/os/sendto_kdc.c b/usr/src/lib/gss_mechs/mech_krb5/krb5/os/sendto_kdc.c
index 87d1dce33a..2d36717023 100644
--- a/usr/src/lib/gss_mechs/mech_krb5/krb5/os/sendto_kdc.c
+++ b/usr/src/lib/gss_mechs/mech_krb5/krb5/os/sendto_kdc.c
@@ -1419,7 +1419,7 @@ krb5int_sendto (krb5_context context, const krb5_data *message,
if (localaddr != 0 && localaddrlen != 0 && *localaddrlen > 0)
(void) getsockname(conns[winning_conn].fd, localaddr, localaddrlen);
- if (remoteaddr != 0 && remoteaddrlen != 0 && *remoteaddrlen > 0)
+ if (remoteaddr != 0 && remoteaddrlen != 0 && *remoteaddrlen > 0)
(void) getpeername(conns[winning_conn].fd, remoteaddr, remoteaddrlen);
egress: