change shell and test command & fix sprintf

in main.c ,empty string now use s[0]='\0'
in shell.c ,test_command string processing now use sprintf + count
,instead of strcat each of them
in clib.c ,sprintf does not return write count correctly ,now fixed