/[mailutils]/mailutils/pop3d/extra.c
ViewVC logotype

Diff of /mailutils/pop3d/extra.c

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

revision 1.17 by polak, Mon Dec 23 22:01:35 2002 UTC revision 1.18 by polak, Fri Jan 3 10:46:12 2003 UTC
# Line 1  Line 1 
1  /* GNU Mailutils -- a suite of utilities for electronic mail  /* GNU Mailutils -- a suite of utilities for electronic mail
2     Copyright (C) 1999, 2001, 2002 Free Software Foundation, Inc.     Copyright (C) 1999, 2001, 2002, 2003 Free Software Foundation, Inc.
3    
4     GNU Mailutils is free software; you can redistribute it and/or modify     GNU Mailutils is free software; you can redistribute it and/or modify
5     it under the terms of the GNU General Public License as published by     it under the terms of the GNU General Public License as published by
# Line 13  Line 13 
13    
14     You should have received a copy of the GNU General Public License     You should have received a copy of the GNU General Public License
15     along with GNU Mailutils; if not, write to the Free Software     along with GNU Mailutils; if not, write to the Free Software
16     Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.  */     Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307  USA  */
17    
18  #include "pop3d.h"  #include "pop3d.h"
19    
# Line 151  pop3d_outf (const char *fmt, ...) Line 151  pop3d_outf (const char *fmt, ...)
151    
152  /* Gets a line of input from the client, caller should free() */  /* Gets a line of input from the client, caller should free() */
153  char *  char *
154  pop3d_readline (FILE *fp)  pop3d_readline (char *buffer, int size)
155  {  {
   static char buffer[512];  
156    char *ptr;    char *ptr;
157    
158    alarm (daemon_param.timeout);    alarm (daemon_param.timeout);
159    ptr = fgets (buffer, sizeof (buffer), fp);    ptr = fgets (buffer, size, ifile);
160    alarm (0);    alarm (0);
161    
162    /* We should probably check ferror() too, but if ptr is null we    /* We should probably check ferror() too, but if ptr is null we
163       are done anyway;  if (!ptr && ferror(fp)) */       are done anyway;  if (!ptr && ferror(ifile)) */
164    if (!ptr)    if (!ptr)
165      pop3d_abquit (ERR_NO_OFILE);      pop3d_abquit (ERR_NO_OFILE);
166    

Legend:
Removed from v.1.17  
changed lines
  Added in v.1.18

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26