Introduced static variables in places where the return value is a plain string

This commit is contained in:
Vladyslav Baranovskyi
2024-12-20 17:02:32 +02:00
parent 3748c9b150
commit b37b8dc639
3 changed files with 12 additions and 6 deletions

View File

@@ -66,7 +66,8 @@ namespace OpenVulkano
const std::string& SystemInfo::GetUserName()
{
return "";
static const std::string userName = "";
return userName;
}
const std::string& SystemInfo::GetHostName()
@@ -83,7 +84,8 @@ namespace OpenVulkano
const std::string& SystemInfo::GetDeviceVendorName()
{
return "Apple";
static const std::string vendorName = "Apple";
return vendorName;
}
const std::string& SystemInfo::GetDeviceModelName()