[BACK]Return to tftp.c CVS log [TXT][DIR] Up to [local] / src / usr.bin / tftp

Diff for /src/usr.bin/tftp/tftp.c between version 1.13 and 1.14

version 1.13, 2003/06/10 22:20:53 version 1.14, 2003/06/25 15:45:10
Line 88 
Line 88 
  * Send the requested file.   * Send the requested file.
  */   */
 void  void
 sendfile(fd, name, mode)  sendfile(int fd, char *name, char *mode)
         int fd;  
         char *name;  
         char *mode;  
 {  {
         struct tftphdr *dp, *ap;           /* data and ack packets */          struct tftphdr *dp, *ap;           /* data and ack packets */
         volatile int block, size, convert;          volatile int block, size, convert;
Line 191 
Line 188 
  * Receive a file.   * Receive a file.
  */   */
 void  void
 recvfile(fd, name, mode)  recvfile(int fd, char *name, char *mode)
         int fd;  
         char *name;  
         char *mode;  
 {  {
         struct tftphdr *dp, *ap;          struct tftphdr *dp, *ap;
         volatile int block, size, firsttrip;          volatile int block, size, firsttrip;
Line 298 
Line 292 
 }  }
   
 static int  static int
 makerequest(request, name, tp, mode)  makerequest(int request, const char *name, struct tftphdr *tp,
         int request;      const char *mode)
         const char *name;  
         struct tftphdr *tp;  
         const char *mode;  
 {  {
         char *cp;          char *cp;
         int len, pktlen;          int len, pktlen;
Line 339 
Line 330 
  * offset by 100.   * offset by 100.
  */   */
 static void  static void
 nak(error)  nak(int error)
         int error;  
 {  {
         struct errmsg *pe;          struct errmsg *pe;
         struct tftphdr *tp;          struct tftphdr *tp;
Line 367 
Line 357 
 }  }
   
 static void  static void
 tpacket(s, tp, n)  tpacket(const char *s, struct tftphdr *tp, int n)
         const char *s;  
         struct tftphdr *tp;  
         int n;  
 {  {
         static char *opcodes[] =          static char *opcodes[] =
            { "#0", "RRQ", "WRQ", "DATA", "ACK", "ERROR" };             { "#0", "RRQ", "WRQ", "DATA", "ACK", "ERROR" };
Line 423 
Line 410 
 }  }
   
 static void  static void
 printstats(direction, amount)  printstats(const char *direction, unsigned long amount)
         const char *direction;  
         unsigned long amount;  
 {  {
         double delta;          double delta;
                         /* compute delta in 1/10's second units */                          /* compute delta in 1/10's second units */
Line 439 
Line 424 
 }  }
   
 static void  static void
 timer(sig)  timer(int sig)
         int sig;  
 {  {
         int save_errno = errno;          int save_errno = errno;
   

Legend:
Removed from v.1.13  
changed lines
  Added in v.1.14