summaryrefslogtreecommitdiff
path: root/modules/gst1/gst.c
diff options
context:
space:
mode:
Diffstat (limited to 'modules/gst1/gst.c')
-rw-r--r--modules/gst1/gst.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/modules/gst1/gst.c b/modules/gst1/gst.c
index 6f704e5..380334a 100644
--- a/modules/gst1/gst.c
+++ b/modules/gst1/gst.c
@@ -3,9 +3,9 @@
*
* Copyright (C) 2010 - 2015 Creytiv.com
*/
+#define _DEFAULT_SOURCE 1
#include <stdlib.h>
#include <string.h>
-#define __USE_POSIX199309
#include <time.h>
#include <pthread.h>
#include <gst/gst.h>
@@ -383,6 +383,12 @@ static int gst_alloc(struct ausrc_st **stp, const struct ausrc *as,
if (!prm)
return EINVAL;
+ if (prm->fmt != AUFMT_S16LE) {
+ warning("gst: unsupported sample format (%s)\n",
+ aufmt_name(prm->fmt));
+ return ENOTSUP;
+ }
+
st = mem_zalloc(sizeof(*st), gst_destructor);
if (!st)
return ENOMEM;