/[LeafOK_CVS]/lbbs/src/io.c
ViewVC logotype

Diff of /lbbs/src/io.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

Revision 1.49 by sysadm, Sat Jun 28 01:16:00 2025 UTC Revision 1.52 by sysadm, Thu Oct 16 12:11:31 2025 UTC
# Line 314  int igetch(int timeout) Line 314  int igetch(int timeout)
314                                                          else if (ret == 0)                                                          else if (ret == 0)
315                                                          {                                                          {
316                                                                  out = 0;                                                                  out = 0;
317                                                                  break; // Check whether channel is still open                                                                  loop = 0;
318                                                                    break;
319                                                          }                                                          }
320                                                  }                                                  }
321                                                  else                                                  else
# Line 377  int igetch(int timeout) Line 378  int igetch(int timeout)
378          {          {
379                  unsigned char c = buf[pos++];                  unsigned char c = buf[pos++];
380    
381                    // Convert \r\n to \r
382                    if (c == CR && pos < len && buf[pos] == LF)
383                    {
384                            pos++;
385                    }
386    
387                    // Convert single \n to \r
388                    if (c == LF)
389                    {
390                            c = CR;
391                    }
392    
393                  if (c == KEY_CONTROL)                  if (c == KEY_CONTROL)
394                  {                  {
395                          if (in_control == 0)                          if (in_control == 0)


Legend:
Removed lines/characters  
Changed lines/characters
  Added lines/characters

webmaster@leafok.com
ViewVC Help
Powered by ViewVC 1.3.0-beta1