From 15ff1d512b9e103396144bec1cd8004ecf4f7f9c Mon Sep 17 00:00:00 2001 From: erihel Date: Sat, 22 Sep 2012 00:11:16 +0200 Subject: * Fixed audio problems * Added colobot.ini to CApp in Create function * Fixes to plugin manager * Fixed CProfile segfault --- src/common/profile.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/common') diff --git a/src/common/profile.cpp b/src/common/profile.cpp index efcfa66..1025567 100644 --- a/src/common/profile.cpp +++ b/src/common/profile.cpp @@ -57,7 +57,7 @@ bool CProfile::SetLocalProfileString(std::string section, std::string key, std:: bool CProfile::GetLocalProfileString(std::string section, std::string key, std::string &buffer) { const char* value = m_ini->GetValue(section.c_str(), key.c_str(), nullptr); - if (strlen(value) > 0) { + if (value != nullptr && strlen(value) > 0) { buffer = std::string(value); return true; } -- cgit v1.2.3-1-g7c22