projects
/
krb5.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
7e9caf0
)
Fix bug where an allocated structure was used before it was checked to
author
Theodore Tso
<tytso@mit.edu>
Thu, 3 Jun 1993 00:11:44 +0000
(
00:11
+0000)
committer
Theodore Tso
<tytso@mit.edu>
Thu, 3 Jun 1993 00:11:44 +0000
(
00:11
+0000)
see if it were null.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@2552
dc483132
-0cff-0310-8789-
dd5450dbe970
src/lib/krb5/krb/copy_auth.c
patch
|
blob
|
history
diff --git
a/src/lib/krb5/krb/copy_auth.c
b/src/lib/krb5/krb/copy_auth.c
index c4352191c5454cc3ab89fc52aba07fb8a796c9ea..f3d19865e24975b7fba3474a1ad7ed4798a64bad 100644
(file)
--- a/
src/lib/krb5/krb/copy_auth.c
+++ b/
src/lib/krb5/krb/copy_auth.c
@@
-65,13
+65,13
@@
krb5_authdata ***outauthdat;
krb5_authdata ** tempauthdat;
register int nelems = 0;
- while (inauthdat[nelems]) nelems++;
-
if (!inauthdat) {
*outauthdat = 0;
return 0;
}
+ while (inauthdat[nelems]) nelems++;
+
/* one more for a null terminated list */
if (!(tempauthdat = (krb5_authdata **) calloc(nelems+1,
sizeof(*tempauthdat))))