tools
This commit is contained in:
10
login.c
10
login.c
@@ -83,7 +83,10 @@ static int get_raw_str(uint8 *s, int maxlen, int doecho)
|
||||
case 8 : if (len) {
|
||||
--len;
|
||||
--s;
|
||||
if (doecho) fprintf(stdout, "\010 \010");
|
||||
if (doecho) {
|
||||
fprintf(stdout, "\010 \010");
|
||||
fflush(stdout);
|
||||
}
|
||||
} else beep();
|
||||
continue;
|
||||
|
||||
@@ -94,7 +97,10 @@ static int get_raw_str(uint8 *s, int maxlen, int doecho)
|
||||
len++;
|
||||
break;
|
||||
} /* switch */
|
||||
if (doecho) fprintf(stdout, "%c", (uint8)key);
|
||||
if (doecho) {
|
||||
fprintf(stdout, "%c", (uint8)key);
|
||||
fflush(stdout);
|
||||
}
|
||||
}
|
||||
*s='\0';
|
||||
return(len);
|
||||
|
||||
Reference in New Issue
Block a user