Branch: refs/heads/master
  Home:   https://github.com/tianocore/edk2
  Commit: 800205678fc9f4d290890de2db1e1de87759da66
      
https://github.com/tianocore/edk2/commit/800205678fc9f4d290890de2db1e1de87759da66
  Author: Tormod Volden <debian.tor...@gmail.com>
  Date:   2024-11-24 (Sun, 24 Nov 2024)

  Changed paths:
    M ShellPkg/Application/Shell/ShellParametersProtocol.c

  Log Message:
  -----------
  ShellPkg: Fix check on OldArgv in UpdateArgcArgv()

The UpdateArgcArgv() function documentation says "If OldArgv or OldArgc
is NULL then that value is not returned."

However, only OldArgc was checked for NULL, probably because of
copy-pasto. In case OldArgc was non-NULL, but OldArgv was null, it could
cause a segmentation fault.

Check OldArgv is not NULL before dereferencing the value.

Signed-off-by: Tormod Volden <debian.tor...@gmail.com>



To unsubscribe from these emails, change your notification settings at 
https://github.com/tianocore/edk2/settings/notifications


_______________________________________________
edk2-commits mailing list
edk2-commits@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/edk2-commits

Reply via email to