From 1f6555c9ad3fb75cb474fbf99b46333830285514 Mon Sep 17 00:00:00 2001 From: Torsten Dreyer Date: Thu, 12 Aug 2010 11:42:04 +0200 Subject: [PATCH] two warning fixes --- simgear/scene/util/StateAttributeFactory.cxx | 2 +- simgear/structure/SGSharedPtr.hxx | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/simgear/scene/util/StateAttributeFactory.cxx b/simgear/scene/util/StateAttributeFactory.cxx index 76124da0..25a0a576 100644 --- a/simgear/scene/util/StateAttributeFactory.cxx +++ b/simgear/scene/util/StateAttributeFactory.cxx @@ -39,7 +39,7 @@ StateAttributeFactory::StateAttributeFactory() { _standardAlphaFunc = new AlphaFunc; _standardAlphaFunc->setFunction(osg::AlphaFunc::GREATER); - _standardAlphaFunc->setReferenceValue(0.01); + _standardAlphaFunc->setReferenceValue(0.01f); _standardAlphaFunc->setDataVariance(Object::STATIC); _smooth = new ShadeModel; _smooth->setMode(ShadeModel::SMOOTH); diff --git a/simgear/structure/SGSharedPtr.hxx b/simgear/structure/SGSharedPtr.hxx index f321b12d..98b72f22 100644 --- a/simgear/structure/SGSharedPtr.hxx +++ b/simgear/structure/SGSharedPtr.hxx @@ -88,7 +88,7 @@ public: { return T::count(_ptr); } bool valid(void) const - { return _ptr; } + { return _ptr != NULL; } void clear() { put(); } -- 2.39.5