diff options
Diffstat (limited to 'apps/netutils/pppd/chat.c')
-rw-r--r-- | apps/netutils/pppd/chat.c | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/apps/netutils/pppd/chat.c b/apps/netutils/pppd/chat.c index ce900f478..e3120f647 100644 --- a/apps/netutils/pppd/chat.c +++ b/apps/netutils/pppd/chat.c @@ -54,6 +54,10 @@ * Private Functions ****************************************************************************/ +/**************************************************************************** + * Name: chat_read_byte + ****************************************************************************/ + static int chat_read_byte(int fd, char* c, int timeout) { int ret; @@ -80,12 +84,20 @@ static int chat_read_byte(int fd, char* c, int timeout) return 0; } +/**************************************************************************** + * Name: chat_flush + ****************************************************************************/ + static void chat_flush(int fd) { char tmp; while (chat_read_byte(fd, &tmp, 0) == 0); } +/**************************************************************************** + * Name: chat_check_response + ****************************************************************************/ + static int chat_check_response(int fd, const char* response, int timeout) { char c; @@ -119,6 +131,14 @@ static int chat_check_response(int fd, const char* response, int timeout) return 0; } +/**************************************************************************** + * Public Functions + ****************************************************************************/ + +/**************************************************************************** + * Name: ppp_chat + ****************************************************************************/ + int ppp_chat(int fd, struct chat_script_s *script, int echo) { int ret; |