Rtems telnetd/shell question

Peter Dufault dufault at hda.com
Tue Oct 27 09:31:32 UTC 2009


I'm trying to use the RTEMS shell with the RTEMS telnetd, and it hangs  
when I close down telnet.  If I close down the telnet session the  
shell task that was spawned by telnetd gets stuck forever in  
rtems_shell_line_editor() in the "empty line" logic at line 755 where  
it thinks it read a blank line, tries to prompt and doesn't see the  
error, and loops forever.

I'm initializing it simply, similar to an example I saw:

static void sh_wrap( char *dev, void *arg)
{
     (void)rtems_shell_main_loop(arg);
}

rtems_telnetd_config_table rtems_telnetd_config = {
     sh_wrap,                /* Command */
     NULL,                   /* Argument */
     0,                      /* Priority */
     RTEMS_MINIMUM_STACK_SIZE * 16, /* task stack size */
     0,                      /* Login check */
     0                       /* Keep stdio of the caller  */
};

rtems_telnetd_initialize();

I can't "exit" the telnet shell, either, it just restarts itself  
without closing the telnet connection.  I tried detecting the error  
when the shell printed the prompt and treating it as an EOF but that  
doesn't help, it must be trying to restart itself.

Peter



More information about the users mailing list