* CalDAV/CardDAV: do NOT use Content-Length header, if zlib.output_compression is enabled, fixes problems with iOS7 eg. eTask app

Content-Length is size AFTER applying transfer encoding which compression is, as compression is done in PHP outside our control, we only set wrong (to big) size
This commit is contained in:
Ralf Becker 2013-11-20 14:12:47 +00:00
parent 9bc3c57239
commit dbd15105e0

View File

@ -367,7 +367,7 @@ abstract class groupdav_handler
if (($ret = $this->get($options, $id ? $id : $this->new_id, $user)) && !empty($options['data'])) if (($ret = $this->get($options, $id ? $id : $this->new_id, $user)) && !empty($options['data']))
{ {
header('Content-Length: '.$this->groupdav->bytes($options['data'])); if (!$this->groupdav->use_compression()) header('Content-Length: '.$this->groupdav->bytes($options['data']));
header('Content-Type: '.$options['mimetype']); header('Content-Type: '.$options['mimetype']);
echo $options['data']; echo $options['data'];
} }