--- tftpd/src/srv.c 2014/02/24 22:21:46 1.7.2.3 +++ tftpd/src/srv.c 2014/02/24 22:26:11 1.7.2.4 @@ -3,7 +3,7 @@ * by Michael Pounov * * $Author: misho $ -* $Id: srv.c,v 1.7.2.3 2014/02/24 22:21:46 misho Exp $ +* $Id: srv.c,v 1.7.2.4 2014/02/24 22:26:11 misho Exp $ * ************************************************************************** The ELWIX and AITNET software is distributed under the following @@ -287,7 +287,7 @@ RQ(sched_task_t *task) cli.siz = TFTP_LOAD_MAX; cli.opc = ntohs(rpack_uint16(pkt, NULL, 0)); if (!RW && cli.opc == TFTP_OPC_WRQ) { - code = 2; + code = htons(2); goto end; } len = str_getString(RPACK_NEXT(pkt), rlen, &str);