Subversion Repositories HelenOS

Rev

Rev 4537 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 4537 Rev 4668
Line 145... Line 145...
145
 * just for command history and making arrows work. */
145
 * just for command history and making arrows work. */
146
void get_input(cliuser_t *usr)
146
void get_input(cliuser_t *usr)
147
{
147
{
148
    char line[INPUT_MAX];
148
    char line[INPUT_MAX];
149
 
149
 
-
 
150
    fflush(stdout);
150
    console_set_style(fphone(stdout), STYLE_EMPHASIS);
151
    console_set_style(fphone(stdout), STYLE_EMPHASIS);
151
    printf("%s", usr->prompt);
152
    printf("%s", usr->prompt);
-
 
153
    fflush(stdout);
152
    console_set_style(fphone(stdout), STYLE_NORMAL);
154
    console_set_style(fphone(stdout), STYLE_NORMAL);
153
 
155
 
154
    read_line(line, INPUT_MAX);
156
    read_line(line, INPUT_MAX);
155
    /* Make sure we don't have rubbish or a C/R happy user */
157
    /* Make sure we don't have rubbish or a C/R happy user */
156
    if (str_cmp(line, "") == 0 || str_cmp(line, "\n") == 0)
158
    if (str_cmp(line, "") == 0 || str_cmp(line, "\n") == 0)