From f714802c8d1835afb0483322309d307c881baca1 Mon Sep 17 00:00:00 2001 From: Martin Heistermann Date: Wed, 8 Nov 2017 11:14:32 +0100 Subject: [PATCH] Add missing break statements in OM::IO::restore --- src/OpenMesh/Core/IO/OMFormatT.cc | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/OpenMesh/Core/IO/OMFormatT.cc b/src/OpenMesh/Core/IO/OMFormatT.cc index a61413b6..fa332b12 100644 --- a/src/OpenMesh/Core/IO/OMFormatT.cc +++ b/src/OpenMesh/Core/IO/OMFormatT.cc @@ -145,7 +145,7 @@ namespace IO { } - // helper to store a an integer + // helper to restore a an integer template< typename T > size_t restore( std::istream& _is, @@ -171,25 +171,28 @@ namespace IO { OMFormat::int16 v; bytes = restore( _is, v, _swap ); _val = static_cast(v); + break; } case OMFormat::Chunk::Integer_32: { OMFormat::int32 v; bytes = restore( _is, v, _swap ); _val = static_cast(v); + break; } case OMFormat::Chunk::Integer_64: { OMFormat::int64 v; bytes = restore( _is, v, _swap ); _val = static_cast(v); + break; } } return bytes; } - // helper to store a an unsigned integer + // helper to restore a an unsigned integer template< typename T > size_t restore( std::istream& _is,