Browse Source

Bugfix: iobuf->data always points to the start of the allocated

portion, not to the bit we want to currently write to...
tags/v0.9.3
Michael Brown 17 years ago
parent
commit
d465ae9785
1 changed files with 1 additions and 1 deletions
  1. 1
    1
      src/net/udp/tftp.c

+ 1
- 1
src/net/udp/tftp.c View File

@@ -165,7 +165,7 @@ static int tftp_send_rrq ( struct tftp_request *tftp ) {
165 165
 	rrq = iob_put ( iobuf, sizeof ( *rrq ) );
166 166
 	rrq->opcode = htons ( TFTP_RRQ );
167 167
 	iob_put ( iobuf,
168
-		  snprintf ( iobuf->data, iob_tailroom ( iobuf ),
168
+		  snprintf ( rrq->data, iob_tailroom ( iobuf ),
169 169
 			     "%s%coctet%cblksize%c%d%ctsize%c0", path, 0,
170 170
 			     0, 0, tftp_request_blksize, 0, 0 ) + 1 );
171 171
 

Loading…
Cancel
Save