gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[GNUnet-SVN] r6077 - in libmicrohttpd: . src/daemon


From: gnunet
Subject: [GNUnet-SVN] r6077 - in libmicrohttpd: . src/daemon
Date: Wed, 2 Jan 2008 16:41:36 -0700 (MST)

Author: grothoff
Date: 2008-01-02 16:41:35 -0700 (Wed, 02 Jan 2008)
New Revision: 6077

Modified:
   libmicrohttpd/AUTHORS
   libmicrohttpd/ChangeLog
   libmicrohttpd/src/daemon/postprocessor.c
Log:
fix

Modified: libmicrohttpd/AUTHORS
===================================================================
--- libmicrohttpd/AUTHORS       2008-01-02 10:22:27 UTC (rev 6076)
+++ libmicrohttpd/AUTHORS       2008-01-02 23:41:35 UTC (rev 6077)
@@ -7,6 +7,7 @@
 Daniel Pittman <address@hidden>
 Nils Durner <address@hidden>
 Heikki Lindholm <address@hidden>
+Alex Sadovsky <address@hidden>
 
 Documentation contributions also came from:
 Marco Maggi <address@hidden>

Modified: libmicrohttpd/ChangeLog
===================================================================
--- libmicrohttpd/ChangeLog     2008-01-02 10:22:27 UTC (rev 6076)
+++ libmicrohttpd/ChangeLog     2008-01-02 23:41:35 UTC (rev 6077)
@@ -1,3 +1,6 @@
+Wed Jan  2 16:41:05 MST 2008
+        Improvements and bugfixes to post processor implementation. - AS
+
 Wed Dec 19 21:12:04 MST 2007
         Implemented chunked (HTTP 1.1) downloads (including
         sending of HTTP footers).  Also allowed queuing of

Modified: libmicrohttpd/src/daemon/postprocessor.c
===================================================================
--- libmicrohttpd/src/daemon/postprocessor.c    2008-01-02 10:22:27 UTC (rev 
6076)
+++ libmicrohttpd/src/daemon/postprocessor.c    2008-01-02 23:41:35 UTC (rev 
6077)
@@ -323,10 +323,14 @@
 static int
 try_match_header (const char *prefix, char *line, char **suffix)
 {
-  if (0 == strncasecmp (prefix, line, strlen (prefix)))
+  while(*line != 0)
     {
-      *suffix = strdup (&line[strlen (prefix)]);
-      return MHD_YES;
+    if (0 == strncasecmp (prefix, line, strlen (prefix)))
+      {
+        *suffix = strdup (&line[strlen (prefix)]);
+        return MHD_YES;
+      }
+    ++line;
     }
   return MHD_NO;
 }
@@ -467,7 +471,7 @@
                 endquote++;
               pp->content_disposition[endquote++] = '\0';       /* remove 
end-quote */
               if ((MHD_YES
-                   == try_match_header (" filename=",
+                   == try_match_header (" filename=\"",
                                         &pp->content_disposition[endquote],
                                         &pp->filename)) &&
                   (pp->filename != NULL) && (0 < strlen (pp->filename)))
@@ -525,6 +529,7 @@
                   ioff += newline;
                   memmove (buf, &buf[ioff], pp->buffer_pos - ioff);
                   pp->buffer_pos -= ioff;
+                  ioff = 0;
                   break;
                 }
               if (newline + blen + 4 < pp->buffer_pos)
@@ -576,8 +581,7 @@
                   newline += 4;
                   continue;
                 }
-
-
+              goto END;
             }
           break;
         case PP_FinalDash:





reply via email to

[Prev in Thread] Current Thread [Next in Thread]