From: Wolfgang Denk Date: Wed, 16 Jan 2008 22:26:24 +0100 Subject: [U-Boot-Users] [PATCH] TFTP: add host ip addr support In-Reply-To: Your message of "Wed, 16 Jan 2008 15:56:40 EST." <1200517000.31842.70.camel@localhost> Message-ID: <20080116212624.AE252243C0@gemini.denx.de> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de In message <1200517000.31842.70.camel@localhost> you wrote: > > #define MAX_LEN 80 > static char tftp_filename[MAX_LEN]; > > strncpy(tftp_filename, str, MAX_LEN); > tftp_filename[MAX_LEN-1] = 0; > > May be truncated, but never overruns. Acked-by: wd at denx.de :-) Except that the length should be 128 to match the boot file name length that BOOTP / DHCP can pass as per RFC. Best regards, Wolfgang Denk -- DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de A committee is a group that keeps the minutes and loses hours. -- Milton Berle