diff options
Diffstat (limited to 'ShellPkg/DynamicCommand/TftpDynamicCommand/Tftp.c')
-rw-r--r-- | ShellPkg/DynamicCommand/TftpDynamicCommand/Tftp.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/ShellPkg/DynamicCommand/TftpDynamicCommand/Tftp.c b/ShellPkg/DynamicCommand/TftpDynamicCommand/Tftp.c index 7e5c73b..a60d6be 100644 --- a/ShellPkg/DynamicCommand/TftpDynamicCommand/Tftp.c +++ b/ShellPkg/DynamicCommand/TftpDynamicCommand/Tftp.c @@ -395,7 +395,11 @@ RunTftp ( }
RemoteFilePath = ShellCommandLineGetRawValue (CheckPackage, 2);
- ASSERT (RemoteFilePath != NULL);
+ if (RemoteFilePath == NULL) {
+ ASSERT (RemoteFilePath != NULL);
+ goto Error;
+ }
+
FilePathSize = StrLen (RemoteFilePath) + 1;
AsciiRemoteFilePath = AllocatePool (FilePathSize);
if (AsciiRemoteFilePath == NULL) {
|