Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
F
ffmpeg
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
submodule
ffmpeg
Commits
5c353eb8
Commit
5c353eb8
authored
Oct 29, 2011
by
Justin Ruggles
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
cook: return AVERROR_PATCHWELCOME instead of ENOTSUP
ENOTSUP is not defined on some systems
parent
e34c6c97
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
7 deletions
+7
-7
cook.c
libavcodec/cook.c
+7
-7
No files found.
libavcodec/cook.c
View file @
5c353eb8
...
...
@@ -1099,7 +1099,7 @@ static av_cold int cook_decode_init(AVCodecContext *avctx)
case
MONO
:
if
(
q
->
nb_channels
!=
1
)
{
av_log_ask_for_sample
(
avctx
,
"Container channels != 1.
\n
"
);
return
AVERROR
(
ENOTSUP
)
;
return
AVERROR
_PATCHWELCOME
;
}
av_log
(
avctx
,
AV_LOG_DEBUG
,
"MONO
\n
"
);
break
;
...
...
@@ -1113,7 +1113,7 @@ static av_cold int cook_decode_init(AVCodecContext *avctx)
case
JOINT_STEREO
:
if
(
q
->
nb_channels
!=
2
)
{
av_log_ask_for_sample
(
avctx
,
"Container channels != 2.
\n
"
);
return
AVERROR
(
ENOTSUP
)
;
return
AVERROR
_PATCHWELCOME
;
}
av_log
(
avctx
,
AV_LOG_DEBUG
,
"JOINT_STEREO
\n
"
);
if
(
avctx
->
extradata_size
>=
16
){
...
...
@@ -1151,7 +1151,7 @@ static av_cold int cook_decode_init(AVCodecContext *avctx)
break
;
default
:
av_log_ask_for_sample
(
avctx
,
"Unknown Cook version.
\n
"
);
return
AVERROR
(
ENOTSUP
)
;
return
AVERROR
_PATCHWELCOME
;
}
if
(
s
>
1
&&
q
->
subpacket
[
s
].
samples_per_channel
!=
q
->
samples_per_channel
)
{
...
...
@@ -1167,7 +1167,7 @@ static av_cold int cook_decode_init(AVCodecContext *avctx)
/* Try to catch some obviously faulty streams, othervise it might be exploitable */
if
(
q
->
subpacket
[
s
].
total_subbands
>
53
)
{
av_log_ask_for_sample
(
avctx
,
"total_subbands > 53
\n
"
);
return
AVERROR
(
ENOTSUP
)
;
return
AVERROR
_PATCHWELCOME
;
}
if
((
q
->
subpacket
[
s
].
js_vlc_bits
>
6
)
||
(
q
->
subpacket
[
s
].
js_vlc_bits
<
2
*
q
->
subpacket
[
s
].
joint_stereo
))
{
...
...
@@ -1178,7 +1178,7 @@ static av_cold int cook_decode_init(AVCodecContext *avctx)
if
(
q
->
subpacket
[
s
].
subbands
>
50
)
{
av_log_ask_for_sample
(
avctx
,
"subbands > 50
\n
"
);
return
AVERROR
(
ENOTSUP
)
;
return
AVERROR
_PATCHWELCOME
;
}
q
->
subpacket
[
s
].
gains1
.
now
=
q
->
subpacket
[
s
].
gain_1
;
q
->
subpacket
[
s
].
gains1
.
previous
=
q
->
subpacket
[
s
].
gain_2
;
...
...
@@ -1189,7 +1189,7 @@ static av_cold int cook_decode_init(AVCodecContext *avctx)
s
++
;
if
(
s
>
MAX_SUBPACKETS
)
{
av_log_ask_for_sample
(
avctx
,
"Too many subpackets > 5
\n
"
);
return
AVERROR
(
ENOTSUP
)
;
return
AVERROR
_PATCHWELCOME
;
}
}
/* Generate tables */
...
...
@@ -1233,7 +1233,7 @@ static av_cold int cook_decode_init(AVCodecContext *avctx)
av_log_ask_for_sample
(
avctx
,
"unknown amount of samples_per_channel = %d
\n
"
,
q
->
samples_per_channel
);
return
AVERROR
(
ENOTSUP
)
;
return
AVERROR
_PATCHWELCOME
;
}
avctx
->
sample_fmt
=
AV_SAMPLE_FMT_FLT
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment