Skip to content

Commit b9567df

Browse files
committed
BUG: Fix Valgrind defect with uninitialized array in doOneDimensionErode
Co-author: Jon Haitz Legarreta Gorroño <jon.haitz.legarreta@gmail.com>
1 parent 420c9f7 commit b9567df

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

include/itkLabelSetUtils.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -257,7 +257,7 @@ doOneDimensionErodeFirstPass(TInIter & inputIterator,
257257
// const RealType magnitude = (magnitudeSign * iscale * iscale)/(2.0 *
258258
// sigma);
259259
const RealType magnitude = (magnitudeSign * iscale * iscale) / (2.0);
260-
LineBufferType lineBuf(lineLength);
260+
LineBufferType lineBuf(lineLength, 0.0);
261261
LabelBufferType labBuf(lineLength);
262262

263263
inputIterator.SetDirection(direction);

0 commit comments

Comments
 (0)