zendframework / zend-http

Http component from Zend Framework
BSD 3-Clause "New" or "Revised" License
134 stars 85 forks source link

Zend\Http\Header\AbstractAccept, "undefined offset: 1" for some accept headers #73

Open GeeH opened 8 years ago

GeeH commented 8 years ago

This issue has been moved from the zendframework repository as part of the bug migration program as outlined here - http://framework.zend.com/blog/2016-04-11-issue-closures.html


Original Issue: https://api.github.com/repos/zendframework/zendframework/issues/7352 User: @jurajseffer Created On: 2015-03-21T13:59:27Z Updated At: 2015-11-06T21:19:42Z Body ZF version tested on: 2.3.3

An application sometimes receives the following (invalid?) accept header:

Accept: text/html,application/xhtml+xml,application/xml;image/png,image/jpeg,image/*;q=0.9,*/*;q=0.8

This causes an "Undefined offset: 1" notice on line 174 in Zend\Http\Header\AbstractAccept

$value = trim($explode[1]);

weierophinney commented 4 years ago

This repository has been closed and moved to laminas/laminas-http; a new issue has been opened at https://github.com/laminas/laminas-http/issues/10.