From 634b57b8e69d8e7e1661257ea731377f2331d14f Mon Sep 17 00:00:00 2001 From: Alexey Khabulyak Date: Tue, 3 Dec 2024 12:53:10 +0300 Subject: [PATCH] format_gsm.c: Added mime type Sometimes it's impossible to get a file extension from URL (eg. http://example.com/gsm/your) so we have to rely on content-type header. Currenly, asterisk does not support content-type for gsm format(unlike wav). Added audio/gsm according to https://www.rfc-editor.org/rfc/rfc4856.html --- formats/format_gsm.c | 1 + 1 file changed, 1 insertion(+) diff --git a/formats/format_gsm.c b/formats/format_gsm.c index 48699b6ac5..87157eae3f 100644 --- a/formats/format_gsm.c +++ b/formats/format_gsm.c @@ -174,6 +174,7 @@ static off_t gsm_tell(struct ast_filestream *fs) static struct ast_format_def gsm_f = { .name = "gsm", .exts = "gsm", + .mime_types = "audio/gsm", .write = gsm_write, .seek = gsm_seek, .trunc = gsm_trunc,