projects
/
profile
/
ivi
/
opencv.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
e143706
)
Fix typo leading to heap corruption in OutputArray::create
author
Andrey Kamaev
<andrey.kamaev@itseez.com>
Sun, 31 Mar 2013 09:40:09 +0000
(13:40 +0400)
committer
Andrey Kamaev
<andrey.kamaev@itseez.com>
Sun, 31 Mar 2013 09:40:09 +0000
(13:40 +0400)
modules/core/src/matrix.cpp
patch
|
blob
|
history
diff --git
a/modules/core/src/matrix.cpp
b/modules/core/src/matrix.cpp
index
11a4b02
..
6abc6df
100644
(file)
--- a/
modules/core/src/matrix.cpp
+++ b/
modules/core/src/matrix.cpp
@@
-1546,10
+1546,10
@@
void _OutputArray::create(int dims, const int* sizes, int mtype, int i, bool all
int _type = CV_MAT_TYPE(flags);
for( size_t j = len0; j < len; j++ )
{
- if( v[
i
].type() == _type )
+ if( v[
j
].type() == _type )
continue;
- CV_Assert( v[
i
].empty() );
- v[
i].flags = (v[i
].flags & ~CV_MAT_TYPE_MASK) | _type;
+ CV_Assert( v[
j
].empty() );
+ v[
j].flags = (v[j
].flags & ~CV_MAT_TYPE_MASK) | _type;
}
}
return;