mirror of https://github.com/axmolengine/axmol.git
Merge pull request #6399 from dumganhar/v3
fullPathForFilename optimization: Checking whether the path is an empty string.
This commit is contained in:
commit
35207fd8ba
|
@ -680,6 +680,11 @@ std::string FileUtils::getPathForFilename(const std::string& filename, const std
|
|||
|
||||
std::string FileUtils::fullPathForFilename(const std::string &filename)
|
||||
{
|
||||
if (filename.empty())
|
||||
{
|
||||
return "";
|
||||
}
|
||||
|
||||
if (isAbsolutePath(filename))
|
||||
{
|
||||
return filename;
|
||||
|
|
Loading…
Reference in New Issue