[8809] in Athena Bugs
7.3P rkinitd off by one error in reporting errors
daemon@ATHENA.MIT.EDU (epeisach@Athena.MIT.EDU)
Wed Jan 8 11:49:51 1992
From: epeisach@Athena.MIT.EDU
Date: Wed, 8 Jan 92 11:49:40 -0500
To: bugs@Athena.MIT.EDU
rkinitd when sending an error sends a string over the wire which is not
NULL terminated. The length is known, but the NULL is never appended.
When the error message is printed out (when running under saber), it is
apparent what is wrong.
RCS file: rpc.c,v
retrieving revision 1.1
diff -c -r1.1 rpc.c
*** /tmp/,RCSt1a20739 Wed Jan 8 11:47:19 1992
--- rkinit/rkinitd/rpc.c Wed Jan 8 11:47:07 1992
***************
*** 147,153 ****
char *errmsg;
#endif /* __STDC__ */
{
! if (rki_send_packet(out, MT_STATUS, strlen(errmsg), errmsg)) {
error();
exit(1);
}
--- 147,153 ----
char *errmsg;
#endif /* __STDC__ */
{
! if (rki_send_packet(out, MT_STATUS, strlen(errmsg)+1, errmsg)) {
error();
exit(1);
}