Fixed cppcheck warnings
git-svn-id: http://www.openmesh.org/svnrepo/OpenMesh/trunk@485 fdac6126-5c0c-442c-9429-916003d36597
This commit is contained in:
@@ -112,6 +112,7 @@ void DecimaterViewerWidget::keyPressEvent(QKeyEvent* _event)
|
|||||||
|
|
||||||
default:
|
default:
|
||||||
this->inherited_t::keyPressEvent(_event);
|
this->inherited_t::keyPressEvent(_event);
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -330,7 +330,7 @@ read(std::istream& _in, BaseImporter& _bi, Options& _opt)
|
|||||||
|
|
||||||
omlog() << " " << materials_.size() << " materials loaded.\n";
|
omlog() << " " << materials_.size() << " materials loaded.\n";
|
||||||
|
|
||||||
for ( MaterialList::iterator material = materials_.begin(); material != materials_.end(); material++ )
|
for ( MaterialList::iterator material = materials_.begin(); material != materials_.end(); ++material )
|
||||||
{
|
{
|
||||||
// Save the texture information in a property
|
// Save the texture information in a property
|
||||||
if ( (*material).second.has_map_Kd() )
|
if ( (*material).second.has_map_Kd() )
|
||||||
|
|||||||
@@ -614,9 +614,6 @@ _OMReader_::restore_binary_custom_data( std::istream& _is, BaseProperty* _bp,
|
|||||||
|
|
||||||
if ( _bp )
|
if ( _bp )
|
||||||
{
|
{
|
||||||
#if defined(OM_DEBUG)
|
|
||||||
size_t b;
|
|
||||||
#endif
|
|
||||||
size_t n_bytes = _bp->size_of( _n_elem );
|
size_t n_bytes = _bp->size_of( _n_elem );
|
||||||
|
|
||||||
if ( ((n_bytes == BaseProperty::UnknownSize) || (n_bytes == block_size)) &&
|
if ( ((n_bytes == BaseProperty::UnknownSize) || (n_bytes == block_size)) &&
|
||||||
@@ -624,6 +621,7 @@ _OMReader_::restore_binary_custom_data( std::istream& _is, BaseProperty* _bp,
|
|||||||
(_n_elem * _bp->element_size() == block_size) ) )
|
(_n_elem * _bp->element_size() == block_size) ) )
|
||||||
{
|
{
|
||||||
#if defined(OM_DEBUG)
|
#if defined(OM_DEBUG)
|
||||||
|
size_t b;
|
||||||
bytes += (b=_bp->restore( _is, _swap ));
|
bytes += (b=_bp->restore( _is, _swap ));
|
||||||
#else
|
#else
|
||||||
bytes += _bp->restore( _is, _swap );
|
bytes += _bp->restore( _is, _swap );
|
||||||
|
|||||||
@@ -145,29 +145,13 @@ _OMWriter_::write(std::ostream& _os, BaseExporter& _be, Options _opt) const
|
|||||||
_opt += Options::LSB;
|
_opt += Options::LSB;
|
||||||
_opt -= Options::MSB;
|
_opt -= Options::MSB;
|
||||||
|
|
||||||
// if ( _opt.check(Options::Binary) )
|
|
||||||
// {
|
|
||||||
return write_binary(_os, _be, _opt);
|
return write_binary(_os, _be, _opt);
|
||||||
// }
|
|
||||||
// else
|
|
||||||
// {
|
|
||||||
// return write_ascii(_os, _be, _opt);
|
|
||||||
// }
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//-----------------------------------------------------------------------------
|
//-----------------------------------------------------------------------------
|
||||||
|
|
||||||
|
|
||||||
// bool _OMWriter_::write_ascii(std::ostream& _os, BaseExporter& _be,
|
|
||||||
// Options _opt) const
|
|
||||||
// {
|
|
||||||
// return false;
|
|
||||||
// }
|
|
||||||
|
|
||||||
//-----------------------------------------------------------------------------
|
|
||||||
|
|
||||||
|
|
||||||
#ifndef DOXY_IGNORE_THIS
|
#ifndef DOXY_IGNORE_THIS
|
||||||
template <typename T> struct Enabler
|
template <typename T> struct Enabler
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -229,7 +229,7 @@ static const unsigned long clockticks = CLOCKS_PER_SEC;
|
|||||||
class TimerImplStd : public TimerImpl
|
class TimerImplStd : public TimerImpl
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
TimerImplStd() : freq_(clockticks) { reset(); }
|
TimerImplStd() : freq_(clockticks),count_(0),start_(0) { reset(); }
|
||||||
~TimerImplStd() { ; }
|
~TimerImplStd() { ; }
|
||||||
|
|
||||||
virtual void reset(void) { count_ = 0; }
|
virtual void reset(void) { count_ = 0; }
|
||||||
|
|||||||
Reference in New Issue
Block a user