Fix some cppcheck warnings.
This commit is contained in:
parent
8c58c7b05e
commit
0447aa9814
2 changed files with 4 additions and 3 deletions
|
@ -122,7 +122,7 @@ void StartMap(const std::string &filename, bool clean)
|
|||
}
|
||||
GetDefaultTextColors(nc, rc);
|
||||
|
||||
CreateGame(filename.c_str(), &Map);
|
||||
CreateGame(filename, &Map);
|
||||
|
||||
UI.StatusLine.Set(NameLine);
|
||||
SetMessage("%s", _("Do it! Do it now!"));
|
||||
|
|
|
@ -508,11 +508,12 @@ long CFile::PImpl::tell()
|
|||
*/
|
||||
static bool FindFileWithExtension(char *file, size_t filesize)
|
||||
{
|
||||
char buf[PATH_MAX];
|
||||
|
||||
if (!access(file, R_OK)) {
|
||||
return true;
|
||||
}
|
||||
#if defined(USE_ZLIB) || defined(USE_BZ2LIB)
|
||||
char buf[PATH_MAX];
|
||||
#endif
|
||||
#ifdef USE_ZLIB // gzip or bzip2 in global shared directory
|
||||
sprintf(buf, "%s.gz", file);
|
||||
if (!access(buf, R_OK)) {
|
||||
|
|
Loading…
Add table
Reference in a new issue