X-Git-Url: https://git.distorted.org.uk/~mdw/disorder/blobdiff_plain/929f577e4845639606f0d0297f5b4fff51032051..d7255a305a1c7e583dc9c3ffb1c373ff7da98da6:/clients/resample.c
diff --git a/clients/resample.c b/clients/resample.c
index 6c0bd3f..f02cde7 100644
--- a/clients/resample.c
+++ b/clients/resample.c
@@ -11,10 +11,13 @@
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
- *
+ *
* You should have received a copy of the GNU General Public License
* along with this program. If not, see .
*/
+/** @file clients/resample.c
+ * @brief Audio resampler
+ */
#include "common.h"
#include
@@ -56,7 +59,7 @@ static const struct option options[] = {
};
/* display usage message and terminate */
-static void help(void) {
+static void attribute((noreturn)) help(void) {
xprintf("Usage:\n"
" resample [OPTIONS] < INPUT > OUTPUT\n"
"Options:\n"
@@ -116,6 +119,7 @@ int main(int argc, char **argv) {
case 'n': case 'N': input_endian = ENDIAN_NATIVE; break;
default: disorder_fatal(0, "unknown endianness '%s'", optarg);
}
+ break;
case 'B': output_bits = atoi(optarg); break;
case 'C': output_channels = atoi(optarg); break;
case 'R': output_rate = atoi(optarg); break;
@@ -128,7 +132,8 @@ int main(int argc, char **argv) {
case 'n': case 'N': output_endian = ENDIAN_NATIVE; break;
default: disorder_fatal(0, "unknown endianness '%s'", optarg);
}
- default: fatal(0, "invalid option");
+ break;
+ default: disorder_fatal(0, "invalid option");
}
}
struct resampler rs[1];