]> git.ipfire.org Git - thirdparty/curl.git/commitdiff
http_aws_sigv4: remove useless assignment
authorDaniel Stenberg <daniel@haxx.se>
Fri, 19 Apr 2024 12:12:36 +0000 (14:12 +0200)
committerDaniel Stenberg <daniel@haxx.se>
Fri, 19 Apr 2024 21:46:54 +0000 (23:46 +0200)
This code assigned the variable the same value it already had

Spotted by CodeSonar

Closes #13426

lib/http_aws_sigv4.c

index c9382918ed6f928363adfb6e3231d5ca5e63e836..98cc033a08346306ae23ee1b033e19ebfc9d28cc 100644 (file)
@@ -158,10 +158,7 @@ static CURLcode make_headers(struct Curl_easy *data,
   msnprintf(date_full_hdr, DATE_FULL_HDR_LEN,
             "x-%s-date:%s", provider1, timestamp);
 
-  if(Curl_checkheaders(data, STRCONST("Host"))) {
-    head = NULL;
-  }
-  else {
+  if(!Curl_checkheaders(data, STRCONST("Host"))) {
     char full_host[FULL_HOST_LEN + 1];
 
     if(data->state.aptr.host) {