[Fix] Minor correctness change in lfile.c

This commit is contained in:
Allanis 2014-03-13 20:07:52 +00:00
parent 1c1fcd8486
commit c743205286

View File

@ -22,13 +22,13 @@
#include "log.h" #include "log.h"
#include "lfile.h" #include "lfile.h"
static char lephisto_base[PATH_MAX] = "\0"; /**< Store Lephisto's base path. */
/** /**
* @fn char* lfile_basePath(void) * @fn char* lfile_basePath(void)
* *
* @brief Get Lephisto's base path (for saves etc..). * @brief Get Lephisto's base path (for saves etc..).
* @return The base path to Lephisto. * @return The base path to Lephisto.
*/ */
static char lephisto_base[128] = "\0"; /**< Store Lephisto's base path. */
char* lfile_basePath(void) { char* lfile_basePath(void) {
char* home; char* home;
@ -80,7 +80,7 @@ int lfile_dirMakeExist(const char* path, ...) {
stat(file, &buf); stat(file, &buf);
if(!S_ISDIR(buf.st_mode)) if(!S_ISDIR(buf.st_mode))
if(mkdir(file, S_IRWXU | S_IRWXG | S_IRWXO) < 0) { if(mkdir(file, S_IRWXU | S_IRWXG | S_IRWXO) < 0) {
WARN("Dir '%s' does not exist and unable to create", path); WARN("Dir '%s' does not exist and unable to create", file);
return -1; return -1;
} }
#else #else