Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
F
ffmpeg.wasm-core
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
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Linshizhi
ffmpeg.wasm-core
Commits
2c5c7f10
Commit
2c5c7f10
authored
Jul 21, 2014
by
Michael Niedermayer
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
avutil/opt: remove dead code from set_string_number()
Signed-off-by:
Michael Niedermayer
<
michaelni@gmx.at
>
parent
4927c0a9
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
8 deletions
+1
-8
opt.c
libavutil/opt.c
+1
-8
No files found.
libavutil/opt.c
View file @
2c5c7f10
...
...
@@ -194,7 +194,7 @@ static int set_string(void *obj, const AVOption *o, const char *val, uint8_t **d
static
int
set_string_number
(
void
*
obj
,
void
*
target_obj
,
const
AVOption
*
o
,
const
char
*
val
,
void
*
dst
)
{
int
ret
=
0
,
notfirst
=
0
;
int
ret
=
0
;
int
num
,
den
;
char
c
;
...
...
@@ -215,8 +215,6 @@ static int set_string_number(void *obj, void *target_obj, const AVOption *o, con
if
(
*
val
==
'+'
||
*
val
==
'-'
)
{
if
(
o
->
type
==
AV_OPT_TYPE_FLAGS
)
cmd
=
*
(
val
++
);
else
if
(
!
notfirst
)
buf
[
i
++
]
=
*
val
;
}
for
(;
i
<
sizeof
(
buf
)
-
1
&&
val
[
i
]
&&
(
o
->
type
!=
AV_OPT_TYPE_FLAGS
||
val
[
i
]
!=
'+'
&&
val
[
i
]
!=
'-'
);
i
++
)
...
...
@@ -244,10 +242,6 @@ static int set_string_number(void *obj, void *target_obj, const AVOption *o, con
read_number
(
o
,
dst
,
NULL
,
NULL
,
&
intnum
);
if
(
cmd
==
'+'
)
d
=
intnum
|
(
int64_t
)
d
;
else
if
(
cmd
==
'-'
)
d
=
intnum
&~
(
int64_t
)
d
;
}
else
{
read_number
(
o
,
dst
,
&
num
,
&
den
,
&
intnum
);
if
(
cmd
==
'+'
)
d
=
notfirst
*
num
*
intnum
/
den
+
d
;
else
if
(
cmd
==
'-'
)
d
=
notfirst
*
num
*
intnum
/
den
-
d
;
}
if
((
ret
=
write_number
(
obj
,
o
,
dst
,
d
,
1
,
1
))
<
0
)
...
...
@@ -255,7 +249,6 @@ static int set_string_number(void *obj, void *target_obj, const AVOption *o, con
val
+=
i
;
if
(
!*
val
)
return
0
;
notfirst
=
1
;
}
return
0
;
...
...
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