Issue #7082: When falling back to the MIME 'name' parameter, the
correct place to look for it is the Content-Type header. Patch by Darren Worrall.
This commit is contained in:
parent
9586cf8677
commit
0c8bee6393
|
@ -674,7 +674,7 @@ class Message:
|
||||||
missing = object()
|
missing = object()
|
||||||
filename = self.get_param('filename', missing, 'content-disposition')
|
filename = self.get_param('filename', missing, 'content-disposition')
|
||||||
if filename is missing:
|
if filename is missing:
|
||||||
filename = self.get_param('name', missing, 'content-disposition')
|
filename = self.get_param('name', missing, 'content-type')
|
||||||
if filename is missing:
|
if filename is missing:
|
||||||
return failobj
|
return failobj
|
||||||
return utils.collapse_rfc2231_value(filename).strip()
|
return utils.collapse_rfc2231_value(filename).strip()
|
||||||
|
|
|
@ -16,16 +16,14 @@ X-Oblique-Strategy: Make a door into a window
|
||||||
|
|
||||||
|
|
||||||
--h90VIIIKmx
|
--h90VIIIKmx
|
||||||
Content-Type: text/plain
|
Content-Type: text/plain; name="msg.txt"
|
||||||
Content-Disposition: inline; name="msg.txt"
|
|
||||||
Content-Transfer-Encoding: 7bit
|
Content-Transfer-Encoding: 7bit
|
||||||
|
|
||||||
a simple kind of mirror
|
a simple kind of mirror
|
||||||
to reflect upon our own
|
to reflect upon our own
|
||||||
|
|
||||||
--h90VIIIKmx
|
--h90VIIIKmx
|
||||||
Content-Type: text/plain
|
Content-Type: text/plain; name="msg.txt"
|
||||||
Content-Disposition: inline; name="msg.txt"
|
|
||||||
Content-Transfer-Encoding: 7bit
|
Content-Transfer-Encoding: 7bit
|
||||||
|
|
||||||
a simple kind of mirror
|
a simple kind of mirror
|
||||||
|
|
|
@ -807,6 +807,7 @@ David Wolever
|
||||||
Klaus-Juergen Wolf
|
Klaus-Juergen Wolf
|
||||||
Dan Wolfe
|
Dan Wolfe
|
||||||
Richard Wolff
|
Richard Wolff
|
||||||
|
Darren Worrall
|
||||||
Gordon Worley
|
Gordon Worley
|
||||||
Thomas Wouters
|
Thomas Wouters
|
||||||
Heiko Wundram
|
Heiko Wundram
|
||||||
|
|
|
@ -398,6 +398,9 @@ Core and Builtins
|
||||||
Library
|
Library
|
||||||
-------
|
-------
|
||||||
|
|
||||||
|
- Issue #7082: When falling back to the MIME 'name' parameter, the
|
||||||
|
correct place to look for it is the Content-Type header.
|
||||||
|
|
||||||
- Issue #7048: Force Decimal.logb to round its result when that result
|
- Issue #7048: Force Decimal.logb to round its result when that result
|
||||||
is too large to fit in the current precision.
|
is too large to fit in the current precision.
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue