Commit 9d3f8f7d authored by jehan's avatar jehan

fix android build

parent 55768644
......@@ -222,13 +222,10 @@ LpConfig * lp_config_new(const char *filename){
if (lpconfig->file!=NULL){
lp_config_parse(lpconfig,lpconfig->file);
fclose(lpconfig->file);
#if !defined(_WIN32_WCE)
#ifndef S_ISREG
#define S_ISREG(mode) ((mode & S_IFMT) == S_IFREG)
#endif
#if !defined(WIN32)
if ((stat(filename,&fileStat) == 0) && (S_ISREG(fileStat.st_mode))) {
/* make existing configuration files non-group/world-accessible */
if (chmod(filename, S_IREAD | S_IWRITE) == -1) {
if (chmod(filename, S_IRUSR | S_IWUSR ) == -1) {
ms_warning("unable to correct permissions on "
"configuration file: %s", strerror(errno));
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment