This commit is contained in:
Oliver Lehmann 1989-05-30 06:47:13 +00:00
parent aa3ac5163b
commit b00b32d853
1 changed files with 24 additions and 0 deletions

View File

@ -0,0 +1,24 @@
# include <stdio.h>
# include "gen.h"
# define CUS_BUF 51
char *AAcustomer()
{
register int fd;
register int i;
static char cbuf[CUS_BUF];
extern char *AApath;
extern char *AAztack();
if (!(*cbuf))
{
if ((fd = open(AAztack(AApath, "/sys/etc/customer"), 0)) < 0)
return ((char *) 0);
if ((i = read(fd, cbuf, CUS_BUF)) < 2)
return ((char *) 0);
close(fd);
cbuf[--i] = 0;
}
return (cbuf);
}