* v4rcp.c (kstream_create_rcp_from_fd, kstream_create_from_fd): Allocate
authorKen Raeburn <raeburn@mit.edu>
Sat, 14 Jul 2001 11:21:03 +0000 (11:21 +0000)
committerKen Raeburn <raeburn@mit.edu>
Sat, 14 Jul 2001 11:21:03 +0000 (11:21 +0000)
correct amount of space for kstream data.  (Patch from Cygnus KerbNet code,
1997.)

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

src/appl/bsd/ChangeLog
src/appl/bsd/v4rcp.c

index d8ace791aebf82961ea8c814b7b94e9ee6310111..bd2356708da8267fbeb343e845114791d6b2558f 100644 (file)
@@ -1,3 +1,9 @@
+2001-07-14  Ken Raeburn  <raeburn@mit.edu>
+
+       * v4rcp.c (kstream_create_rcp_from_fd, kstream_create_from_fd):
+       Allocate correct amount of space for kstream data.  (Patch from
+       Cygnus KerbNet code, 1997.)
+
 2001-07-08  Ezra Peisach  <epeisach@mit.edu>
 
        * login.c (sigint): Declare static.
index d27c16c0cc169f8814c5fed81c4eb836d2aaf5c2..94a5eb153a75aa19cafbf27ea9f43c45aa3c3624 100644 (file)
@@ -123,7 +123,7 @@ static kstream kstream_create_rcp_from_fd(read_fd, write_fd, sched, ivec)
      des_key_schedule *sched;
      des_cblock *ivec;
 {
-  kstream tmp = (kstream)malloc(sizeof(kstream*));
+  kstream tmp = (kstream)malloc(sizeof(*tmp));
   tmp->encrypting = 1;
   tmp->read_fd = read_fd;
   tmp->write_fd = write_fd;
@@ -146,7 +146,7 @@ static kstream kstream_create_from_fd(read_fd, write_fd, sched, session)
      des_cblock *session;
 {
   /* just set it up... */
-  kstream tmp = (kstream)malloc(sizeof(kstream*));
+  kstream tmp = (kstream)malloc(sizeof(*tmp));
   tmp->encrypting = 0;
   tmp->read_fd = read_fd;
   tmp->write_fd = write_fd;