paddr may be NULL. Do not crash if it is.
authorRichard Levitte <levitte@openssl.org>
Thu, 12 Jul 2001 15:54:10 +0000 (15:54 +0000)
committerRichard Levitte <levitte@openssl.org>
Thu, 12 Jul 2001 15:54:10 +0000 (15:54 +0000)
ssl/kssl.c

index 46f63d7f4f00589e9d14ad3a7c7012a7cdd256b0..6fd8e7ea0793427f2804087b0b6a67529e745f9f 100644 (file)
@@ -1429,11 +1429,16 @@ kssl_sget_tkt(  /* UPDATE */    KSSL_CTX                *kssl_ctx,
                printf("\tcaddrs: %p, authdata: %p\n",
                        krb5ticket->enc_part2->caddrs,
                        krb5ticket->enc_part2->authorization_data);
-               printf("\tcaddrs:\n");
-               for (i=0; paddr[i] != NULL; i++)
-                       {  krb5_data d;
-                       d.length=paddr[i]->length; d.data=paddr[i]->contents;
-                       print_krb5_data("\t\tIP: ", &d);
+               if (paddr)
+                       {
+                       printf("\tcaddrs:\n");
+                       for (i=0; paddr[i] != NULL; i++)
+                               {
+                               krb5_data d;
+                               d.length=paddr[i]->length;
+                               d.data=paddr[i]->contents;
+                               print_krb5_data("\t\tIP: ", &d);
+                               }
                        }
                printf("\tstart/auth/end times: %d / %d / %d\n",
                        krb5ticket->enc_part2->times.starttime,