add GetChars() accessors to many FString uses where const char* is wanted.

By no means complete, it's just a start to get rid of that automatic type conversion operator.
This commit is contained in:
Christoph Oelckers 2023-10-03 14:27:13 +02:00
commit 1717ff47b2
28 changed files with 92 additions and 97 deletions

View file

@ -528,7 +528,7 @@ void CreatePath(const char *fn)
{
FString name(fn);
name += '/';
DoCreatePath(name);
DoCreatePath(name.GetChars());
}
else
{
@ -805,13 +805,13 @@ FString ExpandEnvVars(const char *searchpathstring)
if (length != 0)
{
FString varname = FString(dollar + 1, length);
if (stricmp(varname, "progdir") == 0)
if (varname.Compare("progdir") == 0)
{
out += progdir;
}
else
{
char *varvalue = getenv(varname);
char *varvalue = getenv(varname.GetChars());
if ( (varvalue != NULL) && (strlen(varvalue) != 0) )
{
out += varvalue;