* $Author$
* $Header$
*
- * Copyright (C) 1987 by the Massachusetts Institute of Technology
- *
- * $Log$
- * Revision 1.1 1987-07-13 03:50:02 wesommer
- * Initial revision
- *
+ * (c) Copyright 1988 by the Massachusetts Institute of Technology.
+ * For copying and distribution information, please see the file
+ * <mit-copyright.h>.
+ *
*/
#ifndef lint
#include <sys/file.h>
#include <stdio.h>
#include <ctype.h>
+#include <mit-copyright.h>
+
/*ARGSUSED*/
main(argc, argv)
if (c == EOF)
return;
- if (c != EOF && c != ':' && c != '\n')
+ if (c != EOF && c != ':' && c != '\n') {
fprintf(stderr, "Field too wide, truncated\n");
- else {
+ while ((c = getc(f)) != EOF && c != ':' && c != '\n');
+ (void) ungetc(c, f);
+ } else {
*buf++ = 0;
(void) ungetc(c, f);
}