fixed bug in term.c with c_iflag

This commit is contained in:
Edward Emelianov 2022-11-08 22:39:07 +03:00
parent b147fee176
commit 511a83e506
3 changed files with 6 additions and 0 deletions

1
TODO
View File

@ -1 +1,2 @@
BUG in commandline options: '?' don't work!
Add prefixes sl_ to every function for solving further problems

1
term.c
View File

@ -112,6 +112,7 @@ static int tty_init(TTY_descr *descr){
}
descr->tty = descr->oldtty;
descr->tty.c_lflag = 0; // ~(ICANON | ECHO | ECHOE | ISIG)
descr->tty.c_iflag = 0;
descr->tty.c_oflag = 0;
descr->tty.c_cflag = descr->baudrate|CS8|CREAD|CLOCAL; // 9.6k, 8N1, RW, ignore line ctrl
descr->tty.c_cc[VMIN] = 0; // non-canonical mode

View File

@ -298,6 +298,10 @@ extern const char *__progname;
void showhelp(int oindex, myoption *options);
void parseargs(int *argc, char ***argv, myoption *options);
/**
* @brief change_helpstring - change standard help header
* @param str (i) - new format (MAY consist ONE "%s" for progname)
*/
void change_helpstring(char *s);
bool get_suboption(char *str, mysuboption *opt);