STEPFile: fix coverity findings.

pull/1263/head
Kim Kulling 2017-05-10 18:50:51 +02:00
parent d36fbfbb8b
commit 5411f769e8
1 changed files with 9 additions and 8 deletions

View File

@ -439,13 +439,17 @@ namespace STEP {
// ------------------------------------------------------------------------------ // ------------------------------------------------------------------------------
/** Base class for all concrete object instances */ /** Base class for all concrete object instances */
// ------------------------------------------------------------------------------ // ------------------------------------------------------------------------------
class Object class Object {
{
public: public:
virtual ~Object() {}
Object(const char* classname = "unknown") Object(const char* classname = "unknown")
: classname(classname) {} : id( 0 )
, classname(classname) {
// empty
}
virtual ~Object() {
// empty
}
public: public:
@ -460,7 +464,6 @@ namespace STEP {
return dynamic_cast<T&>(*this); return dynamic_cast<T&>(*this);
} }
template <typename T> template <typename T>
const T* ToPtr() const { const T* ToPtr() const {
return dynamic_cast<const T*>(this); return dynamic_cast<const T*>(this);
@ -472,7 +475,6 @@ namespace STEP {
} }
public: public:
uint64_t GetID() const { uint64_t GetID() const {
return id; return id;
} }
@ -490,7 +492,6 @@ namespace STEP {
const char* const classname; const char* const classname;
}; };
template <typename T> template <typename T>
size_t GenericFill(const STEP::DB& db, const EXPRESS::LIST& params, T* in); size_t GenericFill(const STEP::DB& db, const EXPRESS::LIST& params, T* in);
// (intentionally undefined) // (intentionally undefined)