]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
just adding/fixing some comments with httpStatusLineParse()
authorwessels <>
Thu, 15 Sep 2005 02:56:33 +0000 (02:56 +0000)
committerwessels <>
Thu, 15 Sep 2005 02:56:33 +0000 (02:56 +0000)
src/HttpStatusLine.cc

index be37b0e5ffc69c3891a79ee9b5eff21ba5e9a23e..098cf0fc3799ca65bba12b9777b735a6dbde3765 100644 (file)
@@ -1,6 +1,6 @@
 
 /*
- * $Id: HttpStatusLine.cc,v 1.29 2005/09/12 23:28:57 wessels Exp $
+ * $Id: HttpStatusLine.cc,v 1.30 2005/09/14 20:56:33 wessels Exp $
  *
  * DEBUG: section 57    HTTP Status-line
  * AUTHOR: Alex Rousskov
@@ -77,14 +77,17 @@ httpStatusLinePackInto(const HttpStatusLine * sline, Packer * p)
                  sline->version.minor, sline->status, httpStatusLineReason(sline));
 }
 
-/* pack fields using Packer */
+/*
+ * Parse character string into 'sline'.  Note 'end' currently unused,
+ * so NULL-termination assumed.
+ */
 int
 httpStatusLineParse(HttpStatusLine * sline, const String &protoPrefix, const char *start, const char *end)
 {
     assert(sline);
     sline->status = HTTP_INVALID_HEADER;       /* Squid header parsing error */
 
-    // XXX: HttpReply::parse() has a similar check but is using
+    // XXX: HttpMsg::parse() has a similar check but is using
     // casesensitive comparison (which is required by HTTP errata?)
 
     if (protoPrefix.caseCmp(start, protoPrefix.size()) != 0)
@@ -105,6 +108,7 @@ httpStatusLineParse(HttpStatusLine * sline, const String &protoPrefix, const cha
     sline->status = (http_status) atoi(++start);
 
     /* we ignore 'reason-phrase' */
+    /* Should assert start < end ? */
     return 1;                  /* success */
 }