mirror of
https://gitlab.freedesktop.org/pulseaudio/pulseaudio.git
synced 2025-11-03 09:01:50 -05:00
win32: Make some unused-variable warnings go away
This commit is contained in:
parent
3adc43b8fe
commit
5818a2c63e
15 changed files with 49 additions and 29 deletions
|
|
@ -470,6 +470,10 @@ static int parse_nice_level(const char *filename, unsigned line, const char *sec
|
|||
}
|
||||
|
||||
static int parse_rtprio(const char *filename, unsigned line, const char *section, const char *lvalue, const char *rvalue, void *data, void *userdata) {
|
||||
#ifdef OS_IS_WIN32
|
||||
pa_log("[%s:%u] Realtime priority not available on win32.", filename, line);
|
||||
#else
|
||||
# ifdef HAVE_SCHED_H
|
||||
pa_daemon_conf *c = data;
|
||||
int32_t rtprio;
|
||||
|
||||
|
|
@ -478,16 +482,15 @@ static int parse_rtprio(const char *filename, unsigned line, const char *section
|
|||
pa_assert(rvalue);
|
||||
pa_assert(data);
|
||||
|
||||
#ifndef OS_IS_WIN32
|
||||
# ifdef HAVE_SCHED_H
|
||||
if (pa_atoi(rvalue, &rtprio) < 0 || rtprio < sched_get_priority_min(SCHED_FIFO) || rtprio > sched_get_priority_max(SCHED_FIFO)) {
|
||||
pa_log("[%s:%u] Invalid realtime priority '%s'.", filename, line, rvalue);
|
||||
return -1;
|
||||
}
|
||||
# endif
|
||||
#endif
|
||||
|
||||
c->realtime_priority = (int) rtprio;
|
||||
# endif
|
||||
#endif /* OS_IS_WIN32 */
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -748,7 +748,9 @@ int main(int argc, char *argv[]) {
|
|||
}
|
||||
|
||||
if (conf->daemonize) {
|
||||
#ifdef HAVE_FORK
|
||||
pid_t child;
|
||||
#endif
|
||||
|
||||
if (pa_stdio_acquire() < 0) {
|
||||
pa_log(_("Failed to acquire stdio."));
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue