#include <stdio.h>
#include <syslog.h>


main()
{
	char buffer[64];
	char line[1024];
	register int n;

	while (fgets(line, sizeof line, stdin) != (char *) NULL) {
		n = snprintf(buffer, sizeof buffer, line);
		printf("strlen(line)=%d, snprintf returned %d, strlen(buffer)=%d\n", strlen(line), n, strlen(buffer));
	}
}
