putchar bug fixed