PVS: V595 The pointer was utilized before it was verified against nullptr
This commit is contained in:
@@ -242,18 +242,19 @@ SbBool SoSFMeshObject::readValue(SoInput *in)
|
||||
// This writes the value of a field to a file.
|
||||
void SoSFMeshObject::writeValue(SoOutput *out) const
|
||||
{
|
||||
if (!out->isBinary()) {
|
||||
SoOutputStream str(out);
|
||||
MeshCore::MeshOutput(value->getKernel()).SaveMeshNode(str);
|
||||
return;
|
||||
}
|
||||
|
||||
if (!value) {
|
||||
int32_t count = 0;
|
||||
out->write(count);
|
||||
out->write(count);
|
||||
return;
|
||||
}
|
||||
|
||||
if (!out->isBinary()) {
|
||||
SoOutputStream str(out);
|
||||
MeshCore::MeshOutput(value->getKernel()).SaveMeshNode(str);
|
||||
return;
|
||||
}
|
||||
|
||||
const MeshCore::MeshPointArray& rPoints = value->getKernel().GetPoints();
|
||||
std::vector<float> verts;
|
||||
verts.reserve(3*rPoints.size());
|
||||
|
||||
Reference in New Issue
Block a user