Skip to content

Commit e47b0d4

Browse files
authored
Gui.cc: return "" instead of nullptr (#2819)
The defaultGuiConfigFile function returns type std::string, so return an empty string instead of nullptr in error cases. Signed-off-by: Steve Peters <scpeters@openrobotics.org>
1 parent d80cb69 commit e47b0d4

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/gui/Gui.cc

+2-2
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@ std::string defaultGuiConfigFile(bool _isPlayback,
8989
{
9090
gzerr << "Failed to create the default config folder ["
9191
<< defaultConfigFolder << "]\n";
92-
return nullptr;
92+
return "";
9393
}
9494
}
9595

@@ -100,7 +100,7 @@ std::string defaultGuiConfigFile(bool _isPlayback,
100100
gzerr << "Failed to copy installed config [" << installedConfig
101101
<< "] to default config [" << defaultConfig << "]."
102102
<< std::endl;
103-
return nullptr;
103+
return "";
104104
}
105105
else
106106
{

0 commit comments

Comments
 (0)