mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-04-04 18:06:22 +03:00
0023280: Pointer to local array is stored outside the scope of this array.
Moved the array 'buff' so it can be visible while 'str' still refers to it.
This commit is contained in:
parent
8418c61723
commit
abd9003d5f
@ -100,10 +100,10 @@ Standard_Boolean OSD_Real2String::CStringToReal(const Standard_CString theString
|
||||
|
||||
|
||||
const char *str = theString;
|
||||
char buff[1024];
|
||||
if (myReadDecimalPoint) {
|
||||
if (myReadDecimalPoint != myLocalDecimalPoint) {
|
||||
const char * p;
|
||||
char buff[1024];
|
||||
const char * p;
|
||||
// replace the decimal point by the local one
|
||||
if(myReadDecimalPoint != myLocalDecimalPoint &&
|
||||
(p = strchr(theString,myReadDecimalPoint))&& ((p-theString) < 1000) )
|
||||
|
Loading…
x
Reference in New Issue
Block a user