"supported senders: %s\n"
"%s",
ut, mmd->num_played,
- getppid(),
+ (int)getppid(),
mmd->active_connections,
mmd->num_commands,
mmd->num_connects,
return NULL;
if (!(logfile = fopen(logfile_name, "a"))) {
PARA_EMERG_LOG("can not open %s, uid: %d\n", logfile_name,
- getuid());
+ (int)getuid());
exit(EXIT_FAILURE);
}
setlinebuf(logfile);
}
if (setgid(g->gr_gid) < 0) {
PARA_EMERG_LOG("failed to set group id %d (%s)\n",
- g->gr_gid, strerror(errno));
+ (int)g->gr_gid, strerror(errno));
exit(EXIT_FAILURE);
}
}
}
PARA_INFO_LOG("%s", "dropping root privileges\n");
setuid(p->pw_uid);
- PARA_DEBUG_LOG("uid: %d, euid: %d\n", getuid(), geteuid());
+ PARA_DEBUG_LOG("uid: %d, euid: %d\n", (int)getuid(), (int)geteuid());
}
/**
PARA_NOTICE_LOG("semaphore set %d was removed\n", id);
return;
}
- PARA_EMERG_LOG("fatal semop error %s: pid %d\n", strerror(errno), getpid());
+ PARA_EMERG_LOG("fatal semop error %s: pid %d\n", strerror(errno),
+ (int)getpid());
exit(EXIT_FAILURE);
}
fprintf(outfd, "%i: ", ll);
mypid = getpid();
if (conf.loglevel_arg <= INFO)
- fprintf(outfd, "(%d) ", mypid);
+ fprintf(outfd, "(%d) ", (int)mypid);
va_start(argp, fmt);
vfprintf(outfd, fmt, argp);
va_end(argp);
if (*pid < 0)
return -ERRNO_TO_PARA_ERROR(errno);
if (WIFEXITED(status))
- PARA_DEBUG_LOG("child %i exited. Exit status: %i\n", *pid,
+ PARA_DEBUG_LOG("child %i exited. Exit status: %i\n", (int)*pid,
WEXITSTATUS(status));
else if (WIFSIGNALED(status))
- PARA_DEBUG_LOG("child %i was killed by signal %i\n", *pid,
+ PARA_DEBUG_LOG("child %i was killed by signal %i\n", (int)*pid,
WTERMSIG(status));
else
- PARA_WARNING_LOG("child %i terminated abormally\n", *pid);
+ PARA_WARNING_LOG("child %i terminated abormally\n", (int)*pid);
return 1;
}