Skip to content

Commit 0cb1398

Browse files
committed
Backport LICENSE.
1 parent 1820f96 commit 0cb1398

File tree

3 files changed

+27
-0
lines changed

3 files changed

+27
-0
lines changed

LICENSE

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
Copyright (c) 2004-2016 Yusuke Shinyama <yusuke at shinyama dot jp>
2+
3+
Permission is hereby granted, free of charge, to any person
4+
obtaining a copy of this software and associated documentation
5+
files (the "Software"), to deal in the Software without
6+
restriction, including without limitation the rights to use,
7+
copy, modify, merge, publish, distribute, sublicense, and/or
8+
sell copies of the Software, and to permit persons to whom the
9+
Software is furnished to do so, subject to the following
10+
conditions:
11+
12+
The above copyright notice and this permission notice shall be
13+
included in all copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY
16+
KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE
17+
WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR
18+
PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
19+
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
20+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
21+
OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
22+
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

MANIFEST.in

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
include Makefile
2+
include LICENSE
23
include *.md
34
include *.py
45
graft docs

pdfminer/pdftypes.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
from .psparser import PSException
1010
from .psparser import PSObject
1111
from .psparser import LIT
12+
from .psparser import STRICT
1213
from . import settings
1314
from .utils import apply_png_predictor
1415
from .utils import isnumber
@@ -229,7 +230,10 @@ def get_filters(self):
229230
if not isinstance(filters, list):
230231
filters = [filters]
231232
if not isinstance(params, list):
233+
# Make sure the parameters list is the same as filters.
232234
params = [params] * len(filters)
235+
if STRICT and len(params) != len(filters):
236+
raise PDFException("Parameters len filter mismatch")
233237
return zip(filters, params)
234238

235239
def decode(self):

0 commit comments

Comments
 (0)