mirror of
https://git.salome-platform.org/gitpub/modules/geom.git
synced 2025-01-13 10:10:34 +05:00
Check if aUnitName is NULL before testing unit value.
This commit is contained in:
parent
8f307e271d
commit
3b485f4d87
@ -101,6 +101,7 @@ IGESIMPORT_EXPORT
|
||||
if (!aModel.IsNull()) {
|
||||
Handle(TCollection_HAsciiString) aUnitName =
|
||||
aModel->GlobalSection().UnitName();
|
||||
if (!aUnitName.IsNull()) {
|
||||
//cout<<"aUnitName = "<<aUnitName->ToCString()<<endl;
|
||||
//cout<<"aUnitFlag = "<<aModel->GlobalSection().UnitFlag()<<endl;
|
||||
if (aUnitName->String()=="MM") {
|
||||
@ -110,6 +111,9 @@ IGESIMPORT_EXPORT
|
||||
P = gp_Pnt(0.01,0.0,0.0);
|
||||
}
|
||||
}
|
||||
//else
|
||||
// cout << "aUnitName is NULL !!" << endl;
|
||||
}
|
||||
BRep_Builder B;
|
||||
TopoDS_Vertex V;
|
||||
B.MakeVertex(V,P,1.e-7);
|
||||
|
Loading…
Reference in New Issue
Block a user