Merge "resource_channels.c: add hangup reason "answered_elsewhere"."
[asterisk/asterisk.git] / codecs / ex_speex.h
index 60ccf09..76e5925 100644 (file)
@@ -18,7 +18,6 @@ static struct ast_frame *speex_sample(void)
 {
        static struct ast_frame f = {
                .frametype = AST_FRAME_VOICE,
-               .subclass.codec = AST_FORMAT_SPEEX,
                .datalen = sizeof(ex_speex),
                /* All frames are 20 ms long */
                .samples = SPEEX_SAMPLES,
@@ -28,6 +27,8 @@ static struct ast_frame *speex_sample(void)
                .data.ptr = ex_speex,
        };
 
+       f.subclass.format = ast_format_speex;
+
        return &f;
 }
 
@@ -49,7 +50,6 @@ static struct ast_frame *speex16_sample(void)
 {
        static struct ast_frame f = {
                .frametype = AST_FRAME_VOICE,
-               .subclass.codec = AST_FORMAT_SPEEX16,
                .datalen = sizeof(ex_speex16),
                /* All frames are 20 ms long */
                .samples = SPEEX_SAMPLES,
@@ -59,5 +59,7 @@ static struct ast_frame *speex16_sample(void)
                .data.ptr = ex_speex16,
        };
 
+       f.subclass.format = ast_format_speex16;
+
        return &f;
 }