Lines Matching refs:buf
22 int shell_readline(int fd, char *buf);
110 void clear_command(int count, char *buf) in clear_command() argument
114 memset(buf, 0, sizeof(buf)); in clear_command()
122 void change_command(char *buf, int type) in change_command() argument
141 strcpy(buf, history_commands[current_command_index]); in change_command()
142 printf("%s", buf); in change_command()
152 int shell_readline(int fd, char *buf) in shell_readline() argument
164 clear_command(count, buf); in shell_readline()
167 change_command(buf, 1); in shell_readline()
168 count = strlen(buf); in shell_readline()
175 clear_command(count, buf); in shell_readline()
178 change_command(buf, -1); in shell_readline()
179 count = strlen(buf); in shell_readline()
203 buf[--count] = 0; in shell_readline()
211 buf[count++] = key; in shell_readline()
219 strcpy(history_commands[count_history], buf); in shell_readline()
224 strcpy(history_commands[current_command_index], buf); in shell_readline()