* fix the server cookie feature.
authorWilfried Göesgens <willi@citadel.org>
Mon, 23 Nov 2009 20:20:14 +0000 (20:20 +0000)
committerWilfried Göesgens <willi@citadel.org>
Mon, 23 Nov 2009 20:20:14 +0000 (20:20 +0000)
webcit/webcit.c

index afcf9cf153afc7c32bb676e9e2b4e1825e6868b0..60bfcc08ee4b80de7f52565001f7a81313043ce7 100644 (file)
@@ -172,9 +172,12 @@ void output_headers(       int do_httpheaders,     /* 1 = output HTTP headers
                if (unset_cookies) {
                        hprintf("Set-cookie: webcit=%s; path=/\r\n", unset);
                } else {
-                       hprintf("Set-cookie: webcit=%s; path=/\r\n", cookie);
                        if (server_cookie != NULL) {
-                               hprintf("%s\n", server_cookie);
+                               hprintf("Set-cookie: webcit=%s; path=/ %s\r\n", 
+                                       cookie, server_cookie);
+                       }
+                       else {
+                               hprintf("Set-cookie: webcit=%s; path=/\r\n", cookie);
                        }
                }
        }