new files

git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@1434 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
Assar Westerlund
1997-03-16 17:14:53 +00:00
parent 11bedf30b0
commit 32a4567759
4 changed files with 149 additions and 1 deletions

23
lib/krb5/net_write.c Normal file
View File

@@ -0,0 +1,23 @@
#include "krb5_locl.h"
RCSID("$Id$");
ssize_t
krb5_net_write (krb5_context context,
int fd,
void *buf,
size_t len)
{
char *cbuf = (char *)buf;
ssize_t count;
size_t rem = len;
while (rem > 0) {
count = write (fd, cbuf, rem);
if (count < 0)
return count;
cbuf += count;
rem -= count;
}
return len;
}