audk/ShellPkg/Library
Ruiyu Ni 452676ffd8 Shellpkg/editor: Fix a bug that may modifies Line[-1]
The original code as below intend to set the character
before last column to CHAR_NULL.
  Line[(LastCol % (ARRAY_SIZE (Line) - 1)) - 1] = CHAR_NULL;

But when LastCol % (ARRAY_SIZE (Line) - 1)) equals to 0,
Line[-1] is modified.

We should change to code as below:
  Line[(LastCol - 1) % (ARRAY_SIZE (Line) - 1)] = CHAR_NULL;

Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
Reviewed-by: Jaben Carsey <jaben.carsey@intel.com>
Reviewed-by: Hao A Wu <hao.a.wu@intel.com>
2017-10-26 13:04:15 +08:00
..
UefiDpLib ShellPkg UefiDpLib: Init CustomCumulativeData.MinDur 2017-08-14 16:55:52 +08:00
UefiHandleParsingLib ShellPkg/HandleParsingLib: Remove unnecessary CatSPrint call 2017-10-25 10:19:31 +08:00
UefiShellBcfgCommandLib ShellPkg/UefiShellBcfgCommandLib: Fix VS2012 build failure 2017-03-15 10:03:23 +08:00
UefiShellCEntryLib ShellPkg: Fix typos in comments and variables 2016-11-15 11:05:34 +08:00
UefiShellCommandLib ShellPkg: Fix bug that fails to change CWD after "map -r". 2017-08-30 11:42:49 +08:00
UefiShellDebug1CommandsLib Shellpkg/editor: Fix a bug that may modifies Line[-1] 2017-10-26 13:04:15 +08:00
UefiShellDriver1CommandsLib ShellPkg/disconnect: '-r' is not optional when disconnecting all 2017-09-29 15:19:10 +08:00
UefiShellInstall1CommandsLib Revert "ShellPkg : Add UEFI_APPLICATION module type to UefiShellInstall1CommandsLib.inf" 2016-01-06 16:23:20 +00:00
UefiShellLevel1CommandsLib ShellPkg: Update sources to include MdePkg protocol definitions 2016-10-19 10:26:16 +08:00
UefiShellLevel2CommandsLib ShellPkg/mkdir: support creating nested directories 2017-08-21 10:42:39 +08:00
UefiShellLevel3CommandsLib ShellPkg/alias: Fix flag parsing logic 2017-10-20 12:54:36 +08:00
UefiShellLib ShellPkg/UefiShellLib: Use a more bright blue/green color 2017-10-17 09:59:50 +08:00
UefiShellNetwork1CommandsLib Ifconfig : Fixed False information about Media State. 2017-10-13 17:14:50 +08:00
UefiShellNetwork2CommandsLib ShellPkg/Ifconfig6: Update error message and add a new line 2017-09-12 16:41:08 +08:00
UefiShellTftpCommandLib TFTP : tftp fix for full volume case 2017-10-24 13:48:48 +08:00