Skip to content

Commit

Permalink
fix a bug with heap buffer overflow (openvinotoolkit#5793)
Browse files Browse the repository at this point in the history
  • Loading branch information
dmitriikhurtin authored and rnugmanx committed Aug 26, 2021
1 parent 25a5e64 commit 5ad4dc6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion inference-engine/src/gna_plugin/layers/gna_layer_info.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -264,7 +264,7 @@ class LayerInfo {
return false;
}
// check dims in between
for (int j = permute.first + 1; j != permute.second; j++) {
for (int j = std::min(permute.first, permute.second) + 1; j < std::max(permute.first, permute.second); j++) {
if (inputsOrderTransformed[j] != 1) {
return false;
}
Expand Down

0 comments on commit 5ad4dc6

Please sign in to comment.