modargs: Fix pa_modargs_get_sample_rate() if no "rate" is present in the modargs

see http://lists.freedesktop.org/archives/pulseaudio-discuss/2013-December/019471.html

Signed-off-by: Peter Meerwald <pmeerw@pmeerw.net>
Reported-by: "poljar (Damir Jelić)" <poljarinho@gmail.com>
modargs: Do not modify alternate_rate in pa_modargs_get_alternate_sample_rate() on failure

Signed-off-by: Peter Meerwald <pmeerw@pmeerw.net>
bootstrap.sh: use /usr/bin/env to find bash

bootstrap.sh uses some non-POSIX features of bash, so we can't use
/bin/sh.  Unlike /bin/sh, bash can be installed anywhere in the path, so
we should use /usr/bin/env to find it.

This helps systems that have bash in /usr/local/bin, for example.
core-util: set_scheduler: check for RLIMIT_RTTIME

set_scheduler() assumes that if sys/resource.h was found then we will
find RLIMIT_RTTIME there, but this is a non-POSIX extension on Linux.

Change the check to ensure that RLIMIT_RTTIME is actually defined.
Linux indeed defines this as a macro, and POSIX specifies that the other
RLIMIT_ constants must be macros, so having this as an #ifdef seems
correct.
bluetooth: Fix profile priority comparison

BugLink: https://bugs.freedesktop.org/show_bug.cgi?id=72414
Add pa_sample_format_valid()

I think this makes the code a bit nicer to read and write. This also
reduces the chances of off-by-one errors when checking the bounds of
the sample format value.
Add pa_sample_rate_valid()

I think this makes the code a bit nicer to read and write. This also
reduces the chances of off-by-one errors when checking the bounds of
sample rate values.
Add pa_channels_valid()

I think this makes the code a bit nicer to read and write. This also
reduces the chances of off-by-one errors when checking the bounds of
channel count values.