فهرست منبع

modify strncasecmp function paramters

stanley-king 9 سال پیش
والد
کامیت
e8c077510a
1فایلهای تغییر یافته به همراه2 افزوده شده و 2 حذف شده
  1. 2 2
      helper/http_header.php

+ 2 - 2
helper/http_header.php

@@ -248,7 +248,7 @@ class http_header
             $colon_offset = strchr($header_line, ':');
             if($colon_offset)
             {
-                if (!strcasecmp($header_line, "Location",strlen("Location")))
+                if (!strncasecmp($header_line, "Location",strlen("Location")))
                 {
                     if( ($this->mStatusCode < 300 || $this->mStatusCode > 399) && $this->mStatusCode != 201)
                     {
@@ -262,7 +262,7 @@ class http_header
                         }
                     }
                 }
-                else if(!strcasecmp($header_line, "WWW-Authenticate",strlen("WWW-Authenticate"))) {
+                else if(!strncasecmp($header_line, "WWW-Authenticate",strlen("WWW-Authenticate"))) {
                     $this->mStatusCode = 401;
                 }
             }