diff options
author | vanjeff <vanjeff@6f19259b-4bc3-4df7-8a09-765794883524> | 2008-01-08 08:15:44 +0000 |
---|---|---|
committer | vanjeff <vanjeff@6f19259b-4bc3-4df7-8a09-765794883524> | 2008-01-08 08:15:44 +0000 |
commit | b7d3c63160fae758c1d0467caeecad169c733338 (patch) | |
tree | fe65218b0a56b7adda036f6f7ebd55cfc9d907ad /MdeModulePkg/Universal/Network/Mtftp4Dxe | |
parent | 06579057489bbdeabc422e49c3a03474ddfb81cf (diff) | |
download | edk2-b7d3c63160fae758c1d0467caeecad169c733338.zip edk2-b7d3c63160fae758c1d0467caeecad169c733338.tar.gz edk2-b7d3c63160fae758c1d0467caeecad169c733338.tar.bz2 |
fixed one bug when calculate the string length.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@4524 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'MdeModulePkg/Universal/Network/Mtftp4Dxe')
-rw-r--r-- | MdeModulePkg/Universal/Network/Mtftp4Dxe/Mtftp4Support.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/MdeModulePkg/Universal/Network/Mtftp4Dxe/Mtftp4Support.c b/MdeModulePkg/Universal/Network/Mtftp4Dxe/Mtftp4Support.c index e56aa15..7cdbddc 100644 --- a/MdeModulePkg/Universal/Network/Mtftp4Dxe/Mtftp4Support.c +++ b/MdeModulePkg/Universal/Network/Mtftp4Dxe/Mtftp4Support.c @@ -305,16 +305,16 @@ Mtftp4SendRequest ( Packet->OpCode = HTONS (Instance->Operation);
Cur = Packet->Rrq.Filename;
Cur = (UINT8 *) AsciiStrCpy ((CHAR8 *) Cur, (CHAR8 *) Token->Filename);
- Cur += AsciiStrLen ((CHAR8 *) Token->Filename);
+ Cur += AsciiStrLen ((CHAR8 *) Token->Filename) + 1;
Cur = (UINT8 *) AsciiStrCpy ((CHAR8 *) Cur, (CHAR8 *) Mode);
- Cur += AsciiStrLen ((CHAR8 *) Mode);
+ Cur += AsciiStrLen ((CHAR8 *) Mode) + 1;
for (Index = 0; Index < Token->OptionCount; ++Index) {
Cur = (UINT8 *) AsciiStrCpy ((CHAR8 *) Cur, (CHAR8 *) Options[Index].OptionStr);
- Cur += AsciiStrLen ((CHAR8 *) Options[Index].OptionStr);
+ Cur += AsciiStrLen ((CHAR8 *) Options[Index].OptionStr) + 1;
Cur = (UINT8 *) AsciiStrCpy ((CHAR8 *) Cur, (CHAR8 *) Options[Index].ValueStr);
- Cur += AsciiStrLen ((CHAR8 *) (CHAR8 *) Options[Index].ValueStr);
+ Cur += AsciiStrLen ((CHAR8 *) (CHAR8 *) Options[Index].ValueStr) + 1;
}
return Mtftp4SendPacket (Instance, Nbuf);
|