1*433d6423SLionel Sambuc /* system services puts() 2*433d6423SLionel Sambuc * 3*433d6423SLionel Sambuc * This is here because gcc converts printf() calls without actual formatting 4*433d6423SLionel Sambuc * in the format string, to puts() calls. While that "feature" can be disabled 5*433d6423SLionel Sambuc * with the -fno-builtin-printf gcc flag, we still don't want the resulting 6*433d6423SLionel Sambuc * mayhem to occur in system servers even when that flag is forgotten. 7*433d6423SLionel Sambuc */ 8*433d6423SLionel Sambuc 9*433d6423SLionel Sambuc #include <stdio.h> 10*433d6423SLionel Sambuc 11*433d6423SLionel Sambuc /* puts() uses kputc() to print characters. */ 12*433d6423SLionel Sambuc void kputc(int c); 13*433d6423SLionel Sambuc puts(const char * s)14*433d6423SLionel Sambucint puts(const char *s) 15*433d6423SLionel Sambuc { 16*433d6423SLionel Sambuc 17*433d6423SLionel Sambuc for (; *s; s++) 18*433d6423SLionel Sambuc kputc(*s); 19*433d6423SLionel Sambuc 20*433d6423SLionel Sambuc kputc('\n'); 21*433d6423SLionel Sambuc kputc('\0'); 22*433d6423SLionel Sambuc 23*433d6423SLionel Sambuc return 0; 24*433d6423SLionel Sambuc } 25