Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Main Repositories
otb
Commits
21f8517f
Commit
21f8517f
authored
Feb 11, 2016
by
Stéphane Albert
Browse files
ENH: Hardened GDALOverviewsBuilder::CountResolutions().
parent
089b617f
Changes
1
Hide whitespace changes
Inline
Side-by-side
Modules/IO/IOGDAL/src/otbGDALOverviewsBuilder.cxx
View file @
21f8517f
...
...
@@ -108,14 +108,17 @@ GDALOverviewsBuilder
unsigned
int
minSize
=
static_cast
<
unsigned
int
>
(
pow
(
factor
,
n
)
);
unsigned
int
count
=
1
;
unsigned
int
size
=
std
::
min
(
m_GdalDataset
->
GetWidth
(),
m_GdalDataset
->
GetHeight
()
);
if
(
size
<
minSize
)
return
0
;
unsigned
int
count
=
0
;
while
(
size
>=
minSize
)
{
++
count
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment