summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorThomas Doerfler <Thomas.Doerfler@embedded-brains.de>2009-04-14 10:52:03 +0000
committerThomas Doerfler <Thomas.Doerfler@embedded-brains.de>2009-04-14 10:52:03 +0000
commitbc28ed2fc629fc4547aaf28cb7cf6a052fcefdfa (patch)
tree3b94d61590586434fcd4d0e4d180f2ded76c1c74
parent2009-02-10 Joel Sherrill <joel.sherrill@oarcorp.com> (diff)
downloadnetwork-demos-bc28ed2fc629fc4547aaf28cb7cf6a052fcefdfa.tar.bz2
Updated telnet demon initialization
-rw-r--r--ChangeLog4
-rw-r--r--telnetd/init.c26
2 files changed, 19 insertions, 11 deletions
diff --git a/ChangeLog b/ChangeLog
index 9860c73..38d1768 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2009-04-14 Sebastian Huber <sebastian.huber@embedded-brains.de>
+
+ * telnetd/init.c: Updated telnet demon initialization.
+
2009-02-10 Joel Sherrill <joel.sherrill@oarcorp.com>
* networkconfig-qemu.h: Add option for qemu to use PCI i82551 NIC.
diff --git a/telnetd/init.c b/telnetd/init.c
index f954306..dad37b8 100644
--- a/telnetd/init.c
+++ b/telnetd/init.c
@@ -186,6 +186,18 @@ void rtemsShell(
#define SHELL_ENTRY rtemsShell
+/*
+ * Telnet demon configuration
+ */
+rtems_telnetd_config_table rtems_telnetd_config = {
+ .command = SHELL_ENTRY,
+ .arg = NULL,
+ .priority = 1, /* We feel important today */
+ .stack_size = 20 * RTEMS_MINIMUM_STACK_SIZE, /* Shell needs a large stack */
+ .login_check = NULL, /* Shell asks for user and password */
+ .keep_stdio = false
+};
+
#endif
/*
@@ -210,18 +222,10 @@ rtems_task Init(
#if defined(REMAIN_ON_CONSOLE)
remain_on_console = true;
#endif
+
+ rtems_telnetd_config.keep_stdio = remain_on_console;
- rtems_telnetd_initialize(
- SHELL_ENTRY, /* "shell" function */
- NULL, /* no context necessary for echoShell */
- remain_on_console, /* true == remain on console */
- /* false == listen on sockets */
- RTEMS_MINIMUM_STACK_SIZE * 20, /* shell needs a large stack */
- 1, /* priority .. we feel important today */
- false /* false = telnetd does NOT ask for password */
- /* true = telnetd asks for password */
- /* RTEMS Shell always asks for user/passwd */
- );
+ rtems_telnetd_initialize();
if ( !remain_on_console )
fprintf(stderr, "============== Deleting Init Task ==============\n");