From 75f8d080a28f2a9076a5f60afeba41ac876a78a4 Mon Sep 17 00:00:00 2001 From: Denis Vlasenko Date: Wed, 22 Nov 2006 15:54:52 +0000 Subject: telnetd: we were having telnetd with is ONLY inetd or ONLY standalone. What if I need to have both?? This patch introduces CONFIG_FEATURE_TELNETD_STANDALONE: y - both, n - only inetd. --- include/libbb.h | 1 + include/usage.h | 18 ++++++++++-------- 2 files changed, 11 insertions(+), 8 deletions(-) (limited to 'include') diff --git a/include/libbb.h b/include/libbb.h index bec3ce11c..1c82cbbba 100644 --- a/include/libbb.h +++ b/include/libbb.h @@ -204,6 +204,7 @@ extern off_t bb_copyfd_size(int fd1, int fd2, off_t size); extern off_t bb_copyfd_eof(int fd1, int fd2); extern char bb_process_escape_sequence(const char **ptr); extern char *bb_get_last_path_component(char *path); +extern int ndelay_on(int fd); extern DIR *xopendir(const char *path); diff --git a/include/usage.h b/include/usage.h index 2a6e335ba..69e958d68 100644 --- a/include/usage.h +++ b/include/usage.h @@ -3034,22 +3034,24 @@ USE_FEATURE_START_STOP_DAEMON_FANCY( \ "computer over a network using the TELNET protocol." #endif -#ifdef CONFIG_FEATURE_TELNETD_INETD +#ifdef CONFIG_FEATURE_TELNETD_STANDALONE #define telnetd_trivial_usage \ - "(inetd mode) [OPTION]" + "[OPTION]" #define telnetd_full_usage \ - "Telnetd uses incoming TELNET connections via inetd.\n" \ + "Telnetd listens for incoming TELNET connections on PORT.\n" \ "Options:\n" \ - "\t-l LOGIN\texec LOGIN on connect (default /bin/sh)\n" \ - "\t-f issue_file\tDisplay issue_file instead of /etc/issue" + "\t-p PORT\t\tlisten for connections on PORT (default 23)\n" \ + "\t-l LOGIN\texec LOGIN on connect\n" \ + "\t-f issue_file\tDisplay issue_file instead of /etc/issue\n" \ + "\t-F\t\tForeground mode\n" \ + "\t-i\t\tInetd mode" #else #define telnetd_trivial_usage \ "[OPTION]" #define telnetd_full_usage \ - "Telnetd listens for incoming TELNET connections on PORT.\n" \ + "Telnetd uses incoming TELNET connections via inetd.\n" \ "Options:\n" \ - "\t-p PORT\tlisten for connections on PORT (default 23)\n" \ - "\t-l LOGIN\texec LOGIN on connect (default /bin/sh)\n" \ + "\t-l LOGIN\texec LOGIN on connect\n" \ "\t-f issue_file\tDisplay issue_file instead of /etc/issue" #endif -- cgit v1.2.3