tags 636805 + pending
thanks

Dear maintainer,

I've prepared an NMU for viewvc (versioned as 1.1.5-1.2) and
uploaded it to DELAYED/2. Please feel free to tell me if I
should delay it longer.

Regards.

-- 
 .''`.  Homepage: http://info.comodo.priv.at/ - OpenPGP key 0xBB3A68018649AA06
 : :' : Debian GNU/Linux user, admin, and developer  -  http://www.debian.org/
 `. `'  Member of VIBE!AT & SPI, fellow of the Free Software Foundation Europe
   `-   NP: Aziza MustafĂ  Zadeh: Aspiration
diff -u viewvc-1.1.5/debian/changelog viewvc-1.1.5/debian/changelog
--- viewvc-1.1.5/debian/changelog
+++ viewvc-1.1.5/debian/changelog
@@ -1,3 +1,13 @@
+viewvc (1.1.5-1.2) unstable; urgency=low
+
+  * Non-maintainer upload.
+  * Fix "viewvc runs extremely slowly (~15s per page)":
+    backport upstream commit r2471 as new patch compression-content-length:
+    don't set Content-Length when compression is used.
+    (Closes: #636805)
+
+ -- gregor herrmann <gre...@debian.org>  Fri, 17 Aug 2012 16:21:49 +0200
+
 viewvc (1.1.5-1.1) unstable; urgency=low
 
   * Non-maintainer upload.
diff -u viewvc-1.1.5/debian/patches/series viewvc-1.1.5/debian/patches/series
--- viewvc-1.1.5/debian/patches/series
+++ viewvc-1.1.5/debian/patches/series
@@ -5,0 +6 @@
+compression-content-length
only in patch2:
unchanged:
--- viewvc-1.1.5.orig/debian/patches/compression-content-length
+++ viewvc-1.1.5/debian/patches/compression-content-length
@@ -0,0 +1,54 @@
+Description: Fix issue #467 (I think...) by not claiming a particular content
+ length when compression would skew that.
+ .
+ * lib/viewvc.py
+   (get_writeready_server_file): Add optional 'content_length'
+     parameter, and the code to handle it.
+   (view_doc): Update call to get_writeready_server_file().
+Origin: upstream, svn r2471
+Bug: http://viewvc.tigris.org/issues/show_bug.cgi?id=467
+Bug-Debian: http://bugs.debian.org/636805
+Author: C. Michael Pilato
+Reviewed-by: gregor herrmann <gre...@debian.org>
+Last-Update: 2012-08-07
+Applied-Upstream: yup
+
+--- a/lib/viewvc.py
++++ b/lib/viewvc.py
+@@ -896,13 +896,17 @@
+ 
+   return template
+ 
+-def get_writeready_server_file(request, content_type=None):
++def get_writeready_server_file(request, content_type=None, content_length=None):
+   """Return a file handle to a response body stream, after outputting
+   any queued special headers (on REQUEST.server) and (optionally) a
+   'Content-Type' header whose value is CONTENT_TYPE.  After this is
+-  called, it is too late to add new headers to the response."""
++  called, it is too late to add new headers to the response.
++  If CONTENT_LENGTH is provided and compression is not in use, also
++  generate a 'Content-Length' header for this response."""
+   if request.gzip_compress_level:
+     request.server.addheader('Content-Encoding', 'gzip')
++  elif content_length is not None:
++    request.server.addheader('Content-Length', content_length)
+   if content_type:
+     request.server.header(content_type)
+   else:
+@@ -2699,7 +2703,6 @@
+     raise debug.ViewVCException('Static file "%s" not available (%s)'
+                                  % (document, str(v)), '404 Not Found')
+ 
+-  request.server.addheader('Content-Length', content_length)
+   if document[-3:] == 'png':
+     mime_type = 'image/png'
+   elif document[-3:] == 'jpg':
+@@ -2710,7 +2713,7 @@
+     mime_type = 'text/css'
+   else: # assume HTML:
+     mime_type = None
+-  copy_stream(fp, get_writeready_server_file(request, mime_type))
++  copy_stream(fp, get_writeready_server_file(request, mime_type, content_length))
+   fp.close()
+ 
+ def rcsdiff_date_reformat(date_str, cfg):

Attachment: signature.asc
Description: Digital signature

Reply via email to