Cc: Wang Fan <fan.w...@intel.com>
Cc: Ye Ting <ting...@intel.com>
Cc: Fu Siyuan <siyuan...@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Wu Jiaxin <jiaxin...@intel.com>
---
 NetworkPkg/HttpDxe/HttpImpl.c | 9 +--------
 1 file changed, 1 insertion(+), 8 deletions(-)

diff --git a/NetworkPkg/HttpDxe/HttpImpl.c b/NetworkPkg/HttpDxe/HttpImpl.c
index fe1c3b7..b3a64cf 100644
--- a/NetworkPkg/HttpDxe/HttpImpl.c
+++ b/NetworkPkg/HttpDxe/HttpImpl.c
@@ -63,11 +63,10 @@ EfiHttpGetModeData (
   if ((This == NULL) || (HttpConfigData == NULL)) {
     return EFI_INVALID_PARAMETER;
   }
 
   HttpInstance = HTTP_INSTANCE_FROM_PROTOCOL (This);
-  ASSERT (HttpInstance != NULL);
 
   if ((HttpConfigData->AccessPoint.IPv6Node == NULL) ||
       (HttpConfigData->AccessPoint.IPv4Node == NULL)) {
     return EFI_INVALID_PARAMETER;
   }
@@ -147,11 +146,11 @@ EfiHttpConfigure (
         (!HttpConfigData->LocalAddressIsIPv6 && 
HttpConfigData->AccessPoint.IPv4Node == NULL)))) {
     return EFI_INVALID_PARAMETER;
   }
 
   HttpInstance = HTTP_INSTANCE_FROM_PROTOCOL (This);
-  ASSERT (HttpInstance != NULL && HttpInstance->Service != NULL);
+  ASSERT (HttpInstance->Service != NULL);
 
   if (HttpConfigData != NULL) {
 
     if (HttpConfigData->HttpVersion >= HttpVersionUnsupported) {
       return EFI_UNSUPPORTED;
@@ -289,11 +288,10 @@ EfiHttpRequest (
       (Request->Method != HttpMethodPost) && (Request->Method != 
HttpMethodPatch)) {
     return EFI_UNSUPPORTED;
   }
 
   HttpInstance = HTTP_INSTANCE_FROM_PROTOCOL (This);
-  ASSERT (HttpInstance != NULL);
 
   //
   // Capture the method into HttpInstance.
   //
   if (Request != NULL) {
@@ -623,12 +621,10 @@ EfiHttpRequest (
 
   if (EFI_ERROR (Status) || NULL == RequestMsg) {
     goto Error3;
   }
 
-  ASSERT (RequestMsg != NULL);
-
   //
   // Every request we insert a TxToken and a response call would remove the 
TxToken.
   // In cases of PUT/POST/PATCH, after an initial request-response pair, we 
would do a
   // continuous request without a response call. So, in such cases, where 
Request
   // structure is NULL, we would not insert a TxToken.
@@ -885,11 +881,10 @@ EfiHttpCancel (
   if (This == NULL) {
     return EFI_INVALID_PARAMETER;
   }
 
   HttpInstance = HTTP_INSTANCE_FROM_PROTOCOL (This);
-  ASSERT (HttpInstance != NULL);
 
   if (HttpInstance->State != HTTP_STATE_TCP_CONNECTED) {
     return EFI_NOT_STARTED;
   }
 
@@ -1543,11 +1538,10 @@ EfiHttpResponse (
   if (HttpMsg == NULL) {
     return EFI_INVALID_PARAMETER;
   }
   
   HttpInstance = HTTP_INSTANCE_FROM_PROTOCOL (This);
-  ASSERT (HttpInstance != NULL);
 
   if (HttpInstance->State != HTTP_STATE_TCP_CONNECTED) {
     return EFI_NOT_STARTED;
   }
 
@@ -1639,11 +1633,10 @@ EfiHttpPoll (
   if (This == NULL) {
     return EFI_INVALID_PARAMETER;
   }
 
   HttpInstance = HTTP_INSTANCE_FROM_PROTOCOL (This);
-  ASSERT (HttpInstance != NULL);
 
   if (HttpInstance->State != HTTP_STATE_TCP_CONNECTED) {
     return EFI_NOT_STARTED;
   }
   
-- 
1.9.5.msysgit.1

_______________________________________________
edk2-devel mailing list
edk2-devel@lists.01.org
https://lists.01.org/mailman/listinfo/edk2-devel

Reply via email to