mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-04-10 18:51:21 +03:00
0031884: Data Exchange - NULL de-reference within STEPCAFControl_Reader::SetSourceCodePage()
Removed methods with unclear usage rules.
This commit is contained in:
parent
4065c66c24
commit
c3da64a686
@ -384,7 +384,7 @@ TCollection_ExtendedString STEPCAFControl_Reader::convertName (const TCollection
|
|||||||
// If source code page is not a NoConversion
|
// If source code page is not a NoConversion
|
||||||
// the string is treated as having UTF-8 coding,
|
// the string is treated as having UTF-8 coding,
|
||||||
// else each character is copied to ExtCharacter.
|
// else each character is copied to ExtCharacter.
|
||||||
return TCollection_ExtendedString (theName, SourceCodePage() != Resource_FormatType_NoConversion);
|
return TCollection_ExtendedString (theName, myReader.StepModel()->SourceCodePage() != Resource_FormatType_NoConversion);
|
||||||
}
|
}
|
||||||
|
|
||||||
//=======================================================================
|
//=======================================================================
|
||||||
@ -4783,26 +4783,6 @@ Standard_Boolean STEPCAFControl_Reader::GetNameMode() const
|
|||||||
return myNameMode;
|
return myNameMode;
|
||||||
}
|
}
|
||||||
|
|
||||||
//=======================================================================
|
|
||||||
//function : SourceCodePage
|
|
||||||
//purpose :
|
|
||||||
//=======================================================================
|
|
||||||
|
|
||||||
Resource_FormatType STEPCAFControl_Reader::SourceCodePage() const
|
|
||||||
{
|
|
||||||
return myReader.StepModel()->SourceCodePage();
|
|
||||||
}
|
|
||||||
|
|
||||||
//=======================================================================
|
|
||||||
//function : SetSourceCodePage
|
|
||||||
//purpose :
|
|
||||||
//=======================================================================
|
|
||||||
|
|
||||||
void STEPCAFControl_Reader::SetSourceCodePage(Resource_FormatType theCode)
|
|
||||||
{
|
|
||||||
myReader.StepModel()->SetSourceCodePage(theCode);
|
|
||||||
}
|
|
||||||
|
|
||||||
//=======================================================================
|
//=======================================================================
|
||||||
//function : SetLayerMode
|
//function : SetLayerMode
|
||||||
//purpose :
|
//purpose :
|
||||||
|
@ -141,13 +141,6 @@ public:
|
|||||||
|
|
||||||
Standard_EXPORT Standard_Boolean GetNameMode() const;
|
Standard_EXPORT Standard_Boolean GetNameMode() const;
|
||||||
|
|
||||||
//! Return the encoding of STEP file for converting names into UNICODE.
|
|
||||||
//! Initialized from "read.step.codepage" variable by constructor, which is Resource_UTF8 by default.
|
|
||||||
Standard_EXPORT Resource_FormatType SourceCodePage() const;
|
|
||||||
|
|
||||||
//! Return the encoding of STEP file for converting names into UNICODE.
|
|
||||||
Standard_EXPORT void SetSourceCodePage (Resource_FormatType theCode);
|
|
||||||
|
|
||||||
//! Set LayerMode for indicate read Layers or not.
|
//! Set LayerMode for indicate read Layers or not.
|
||||||
Standard_EXPORT void SetLayerMode (const Standard_Boolean layermode);
|
Standard_EXPORT void SetLayerMode (const Standard_Boolean layermode);
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user