Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
小白菜888
Ffmpeg
提交
90901860
F
Ffmpeg
项目概览
小白菜888
/
Ffmpeg
通知
3
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
F
Ffmpeg
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
90901860
编写于
12月 01, 2007
作者:
M
Michael Niedermayer
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
stupid code (casting of void*) found by checktree.sh
Originally committed as revision 11117 to
svn://svn.ffmpeg.org/ffmpeg/trunk
上级
7fffc879
变更
7
隐藏空白更改
内联
并排
Showing
7 changed file
with
27 addition
and
27 deletion
+27
-27
ffmpeg.c
ffmpeg.c
+1
-1
ffserver.c
ffserver.c
+2
-2
libavcodec/ppc/dsputil_ppc.c
libavcodec/ppc/dsputil_ppc.c
+1
-1
libavcodec/ratecontrol.c
libavcodec/ratecontrol.c
+1
-1
libavcodec/resample.c
libavcodec/resample.c
+3
-3
libavcodec/vorbis_dec.c
libavcodec/vorbis_dec.c
+18
-18
libavformat/asf-enc.c
libavformat/asf-enc.c
+1
-1
未找到文件。
ffmpeg.c
浏览文件 @
90901860
...
...
@@ -1399,7 +1399,7 @@ static int av_encode(AVFormatContext **output_files,
int
key
;
int
want_sdp
=
1
;
file_table
=
(
AVInputFile
*
)
av_mallocz
(
nb_input_files
*
sizeof
(
AVInputFile
));
file_table
=
av_mallocz
(
nb_input_files
*
sizeof
(
AVInputFile
));
if
(
!
file_table
)
goto
fail
;
...
...
ffserver.c
浏览文件 @
90901860
...
...
@@ -3813,7 +3813,7 @@ static int parse_ffconfig(const char *filename)
if
(
feed
)
{
int
i
;
feed
->
child_argv
=
(
char
**
)
av_mallocz
(
64
*
sizeof
(
char
*
));
feed
->
child_argv
=
av_mallocz
(
64
*
sizeof
(
char
*
));
for
(
i
=
0
;
i
<
62
;
i
++
)
{
get_arg
(
arg
,
sizeof
(
arg
),
&
p
);
...
...
@@ -4190,7 +4190,7 @@ static int parse_ffconfig(const char *filename)
}
if
(
!
errors
)
{
IPAddressACL
*
nacl
=
(
IPAddressACL
*
)
av_mallocz
(
sizeof
(
*
nacl
));
IPAddressACL
*
nacl
=
av_mallocz
(
sizeof
(
*
nacl
));
IPAddressACL
**
naclp
=
0
;
acl
.
next
=
0
;
...
...
libavcodec/ppc/dsputil_ppc.c
浏览文件 @
90901860
...
...
@@ -210,7 +210,7 @@ void clear_blocks_dcbz128_ppc(DCTELEM *blocks)
knows about dcbzl ... */
long
check_dcbzl_effect
(
void
)
{
register
char
*
fakedata
=
(
char
*
)
av_malloc
(
1024
);
register
char
*
fakedata
=
av_malloc
(
1024
);
register
char
*
fakedata_middle
;
register
long
zero
=
0
;
register
long
i
=
0
;
...
...
libavcodec/ratecontrol.c
浏览文件 @
90901860
...
...
@@ -138,7 +138,7 @@ int ff_rate_control_init(MpegEncContext *s)
i
+=
s
->
max_b_frames
;
if
(
i
<=
0
||
i
>=
INT_MAX
/
sizeof
(
RateControlEntry
))
return
-
1
;
rcc
->
entry
=
(
RateControlEntry
*
)
av_mallocz
(
i
*
sizeof
(
RateControlEntry
));
rcc
->
entry
=
av_mallocz
(
i
*
sizeof
(
RateControlEntry
));
rcc
->
num_entries
=
i
;
/* init all to skipped p frames (with b frames we might have a not encoded frame at the end FIXME) */
...
...
libavcodec/resample.c
浏览文件 @
90901860
...
...
@@ -185,15 +185,15 @@ int audio_resample(ReSampleContext *s, short *output, short *input, int nb_sampl
/* XXX: move those malloc to resample init code */
for
(
i
=
0
;
i
<
s
->
filter_channels
;
i
++
){
bufin
[
i
]
=
(
short
*
)
av_malloc
(
(
nb_samples
+
s
->
temp_len
)
*
sizeof
(
short
)
);
bufin
[
i
]
=
av_malloc
(
(
nb_samples
+
s
->
temp_len
)
*
sizeof
(
short
)
);
memcpy
(
bufin
[
i
],
s
->
temp
[
i
],
s
->
temp_len
*
sizeof
(
short
));
buftmp2
[
i
]
=
bufin
[
i
]
+
s
->
temp_len
;
}
/* make some zoom to avoid round pb */
lenout
=
(
int
)(
4
*
nb_samples
*
s
->
ratio
)
+
16
;
bufout
[
0
]
=
(
short
*
)
av_malloc
(
lenout
*
sizeof
(
short
)
);
bufout
[
1
]
=
(
short
*
)
av_malloc
(
lenout
*
sizeof
(
short
)
);
bufout
[
0
]
=
av_malloc
(
lenout
*
sizeof
(
short
)
);
bufout
[
1
]
=
av_malloc
(
lenout
*
sizeof
(
short
)
);
if
(
s
->
input_channels
==
2
&&
s
->
output_channels
==
1
)
{
...
...
libavcodec/vorbis_dec.c
浏览文件 @
90901860
...
...
@@ -237,9 +237,9 @@ static int vorbis_parse_setup_hdr_codebooks(vorbis_context *vc) {
AV_DEBUG
(
" Codebooks: %d
\n
"
,
vc
->
codebook_count
);
vc
->
codebooks
=
(
vorbis_codebook
*
)
av_mallocz
(
vc
->
codebook_count
*
sizeof
(
vorbis_codebook
));
tmp_vlc_bits
=
(
uint8_t
*
)
av_mallocz
(
V_MAX_VLCS
*
sizeof
(
uint8_t
));
tmp_vlc_codes
=
(
uint32_t
*
)
av_mallocz
(
V_MAX_VLCS
*
sizeof
(
uint32_t
));
vc
->
codebooks
=
av_mallocz
(
vc
->
codebook_count
*
sizeof
(
vorbis_codebook
));
tmp_vlc_bits
=
av_mallocz
(
V_MAX_VLCS
*
sizeof
(
uint8_t
));
tmp_vlc_codes
=
av_mallocz
(
V_MAX_VLCS
*
sizeof
(
uint32_t
));
for
(
cb
=
0
;
cb
<
vc
->
codebook_count
;
++
cb
)
{
vorbis_codebook
*
codebook_setup
=&
vc
->
codebooks
[
cb
];
...
...
@@ -351,7 +351,7 @@ static int vorbis_parse_setup_hdr_codebooks(vorbis_context *vc) {
}
// Weed out unused vlcs and build codevector vector
codebook_setup
->
codevectors
=
used_entries
?
(
float
*
)
av_mallocz
(
used_entries
*
codebook_setup
->
dimensions
*
sizeof
(
float
))
:
NULL
;
codebook_setup
->
codevectors
=
used_entries
?
av_mallocz
(
used_entries
*
codebook_setup
->
dimensions
*
sizeof
(
float
))
:
NULL
;
for
(
j
=
0
,
i
=
0
;
i
<
entries
;
++
i
)
{
uint_fast8_t
dim
=
codebook_setup
->
dimensions
;
...
...
@@ -459,7 +459,7 @@ static int vorbis_parse_setup_hdr_floors(vorbis_context *vc) {
vc
->
floor_count
=
get_bits
(
gb
,
6
)
+
1
;
vc
->
floors
=
(
vorbis_floor
*
)
av_mallocz
(
vc
->
floor_count
*
sizeof
(
vorbis_floor
));
vc
->
floors
=
av_mallocz
(
vc
->
floor_count
*
sizeof
(
vorbis_floor
));
for
(
i
=
0
;
i
<
vc
->
floor_count
;
++
i
)
{
vorbis_floor
*
floor_setup
=&
vc
->
floors
[
i
];
...
...
@@ -517,7 +517,7 @@ static int vorbis_parse_setup_hdr_floors(vorbis_context *vc) {
floor_setup
->
data
.
t1
.
x_list_dim
+=
floor_setup
->
data
.
t1
.
class_dimensions
[
floor_setup
->
data
.
t1
.
partition_class
[
j
]];
}
floor_setup
->
data
.
t1
.
list
=
(
floor1_entry_t
*
)
av_mallocz
(
floor_setup
->
data
.
t1
.
x_list_dim
*
sizeof
(
floor1_entry_t
));
floor_setup
->
data
.
t1
.
list
=
av_mallocz
(
floor_setup
->
data
.
t1
.
x_list_dim
*
sizeof
(
floor1_entry_t
));
rangebits
=
get_bits
(
gb
,
4
);
...
...
@@ -623,7 +623,7 @@ static int vorbis_parse_setup_hdr_residues(vorbis_context *vc){
uint_fast8_t
i
,
j
,
k
;
vc
->
residue_count
=
get_bits
(
gb
,
6
)
+
1
;
vc
->
residues
=
(
vorbis_residue
*
)
av_mallocz
(
vc
->
residue_count
*
sizeof
(
vorbis_residue
));
vc
->
residues
=
av_mallocz
(
vc
->
residue_count
*
sizeof
(
vorbis_residue
));
AV_DEBUG
(
" There are %d residues.
\n
"
,
vc
->
residue_count
);
...
...
@@ -684,7 +684,7 @@ static int vorbis_parse_setup_hdr_mappings(vorbis_context *vc) {
uint_fast8_t
i
,
j
;
vc
->
mapping_count
=
get_bits
(
gb
,
6
)
+
1
;
vc
->
mappings
=
(
vorbis_mapping
*
)
av_mallocz
(
vc
->
mapping_count
*
sizeof
(
vorbis_mapping
));
vc
->
mappings
=
av_mallocz
(
vc
->
mapping_count
*
sizeof
(
vorbis_mapping
));
AV_DEBUG
(
" There are %d mappings.
\n
"
,
vc
->
mapping_count
);
...
...
@@ -703,8 +703,8 @@ static int vorbis_parse_setup_hdr_mappings(vorbis_context *vc) {
if
(
get_bits1
(
gb
))
{
mapping_setup
->
coupling_steps
=
get_bits
(
gb
,
8
)
+
1
;
mapping_setup
->
magnitude
=
(
uint_fast8_t
*
)
av_mallocz
(
mapping_setup
->
coupling_steps
*
sizeof
(
uint_fast8_t
));
mapping_setup
->
angle
=
(
uint_fast8_t
*
)
av_mallocz
(
mapping_setup
->
coupling_steps
*
sizeof
(
uint_fast8_t
));
mapping_setup
->
magnitude
=
av_mallocz
(
mapping_setup
->
coupling_steps
*
sizeof
(
uint_fast8_t
));
mapping_setup
->
angle
=
av_mallocz
(
mapping_setup
->
coupling_steps
*
sizeof
(
uint_fast8_t
));
for
(
j
=
0
;
j
<
mapping_setup
->
coupling_steps
;
++
j
)
{
mapping_setup
->
magnitude
[
j
]
=
get_bits
(
gb
,
ilog
(
vc
->
audio_channels
-
1
));
mapping_setup
->
angle
[
j
]
=
get_bits
(
gb
,
ilog
(
vc
->
audio_channels
-
1
));
...
...
@@ -722,7 +722,7 @@ static int vorbis_parse_setup_hdr_mappings(vorbis_context *vc) {
}
if
(
mapping_setup
->
submaps
>
1
)
{
mapping_setup
->
mux
=
(
uint_fast8_t
*
)
av_mallocz
(
vc
->
audio_channels
*
sizeof
(
uint_fast8_t
));
mapping_setup
->
mux
=
av_mallocz
(
vc
->
audio_channels
*
sizeof
(
uint_fast8_t
));
for
(
j
=
0
;
j
<
vc
->
audio_channels
;
++
j
)
{
mapping_setup
->
mux
[
j
]
=
get_bits
(
gb
,
4
);
}
...
...
@@ -784,7 +784,7 @@ static int vorbis_parse_setup_hdr_modes(vorbis_context *vc) {
uint_fast8_t
i
;
vc
->
mode_count
=
get_bits
(
gb
,
6
)
+
1
;
vc
->
modes
=
(
vorbis_mode
*
)
av_mallocz
(
vc
->
mode_count
*
sizeof
(
vorbis_mode
));
vc
->
modes
=
av_mallocz
(
vc
->
mode_count
*
sizeof
(
vorbis_mode
));
AV_DEBUG
(
" There are %d modes.
\n
"
,
vc
->
mode_count
);
...
...
@@ -897,12 +897,12 @@ static int vorbis_parse_id_hdr(vorbis_context *vc){
return
2
;
}
vc
->
channel_residues
=
(
float
*
)
av_malloc
((
vc
->
blocksize
[
1
]
/
2
)
*
vc
->
audio_channels
*
sizeof
(
float
));
vc
->
channel_floors
=
(
float
*
)
av_malloc
((
vc
->
blocksize
[
1
]
/
2
)
*
vc
->
audio_channels
*
sizeof
(
float
));
vc
->
saved
=
(
float
*
)
av_malloc
((
vc
->
blocksize
[
1
]
/
2
)
*
vc
->
audio_channels
*
sizeof
(
float
));
vc
->
ret
=
(
float
*
)
av_malloc
((
vc
->
blocksize
[
1
]
/
2
)
*
vc
->
audio_channels
*
sizeof
(
float
));
vc
->
buf
=
(
float
*
)
av_malloc
(
vc
->
blocksize
[
1
]
*
sizeof
(
float
));
vc
->
buf_tmp
=
(
float
*
)
av_malloc
(
vc
->
blocksize
[
1
]
*
sizeof
(
float
));
vc
->
channel_residues
=
av_malloc
((
vc
->
blocksize
[
1
]
/
2
)
*
vc
->
audio_channels
*
sizeof
(
float
));
vc
->
channel_floors
=
av_malloc
((
vc
->
blocksize
[
1
]
/
2
)
*
vc
->
audio_channels
*
sizeof
(
float
));
vc
->
saved
=
av_malloc
((
vc
->
blocksize
[
1
]
/
2
)
*
vc
->
audio_channels
*
sizeof
(
float
));
vc
->
ret
=
av_malloc
((
vc
->
blocksize
[
1
]
/
2
)
*
vc
->
audio_channels
*
sizeof
(
float
));
vc
->
buf
=
av_malloc
(
vc
->
blocksize
[
1
]
*
sizeof
(
float
));
vc
->
buf_tmp
=
av_malloc
(
vc
->
blocksize
[
1
]
*
sizeof
(
float
));
vc
->
saved_start
=
0
;
ff_mdct_init
(
&
vc
->
mdct
[
0
],
bl0
,
1
);
...
...
libavformat/asf-enc.c
浏览文件 @
90901860
...
...
@@ -493,7 +493,7 @@ static int asf_write_header(AVFormatContext *s)
asf
->
nb_packets
=
0
;
asf
->
last_indexed_pts
=
0
;
asf
->
index_ptr
=
(
ASFIndex
*
)
av_malloc
(
sizeof
(
ASFIndex
)
*
ASF_INDEX_BLOCK
);
asf
->
index_ptr
=
av_malloc
(
sizeof
(
ASFIndex
)
*
ASF_INDEX_BLOCK
);
asf
->
nb_index_memory_alloc
=
ASF_INDEX_BLOCK
;
asf
->
nb_index_count
=
0
;
asf
->
maximum_packet
=
0
;
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录