Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-1.1
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
videolan
vlc-1.1
Commits
224d24d4
Commit
224d24d4
authored
Jun 16, 2004
by
Laurent Aimar
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
* avi: fixed the return value of Seek().
parent
5e40e69a
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
9 deletions
+7
-9
modules/demux/avi/avi.c
modules/demux/avi/avi.c
+7
-9
No files found.
modules/demux/avi/avi.c
View file @
224d24d4
...
...
@@ -1042,8 +1042,6 @@ static int Demux_UnSeekable( demux_t *p_demux )
/*****************************************************************************
* Seek: goto to i_date or i_percent
*****************************************************************************
* Returns -1 in case of error, 0 in case of EOF, 1 otherwise
*****************************************************************************/
static
int
Seek
(
demux_t
*
p_demux
,
mtime_t
i_date
,
int
i_percent
)
{
...
...
@@ -1066,7 +1064,7 @@ static int Seek( demux_t *p_demux, mtime_t i_date, int i_percent )
if
(
i_percent
>=
100
)
{
msg_Warn
(
p_demux
,
"cannot seek so far !"
);
return
(
-
1
)
;
return
VLC_EGENERIC
;
}
i_percent
=
__MAX
(
i_percent
,
0
);
...
...
@@ -1086,14 +1084,14 @@ static int Seek( demux_t *p_demux, mtime_t i_date, int i_percent )
if
(
!
p_stream
||
!
p_stream
->
b_activated
)
{
msg_Warn
(
p_demux
,
"cannot find any selected stream"
);
return
(
-
1
)
;
return
VLC_EGENERIC
;
}
/* be sure that the index exist */
if
(
AVI_StreamChunkSet
(
p_demux
,
i_stream
,
0
)
)
{
msg_Warn
(
p_demux
,
"cannot seek"
);
return
(
-
1
)
;
return
VLC_EGENERIC
;
}
while
(
i_pos
>=
p_stream
->
p_index
[
p_stream
->
i_idxposc
].
i_pos
+
...
...
@@ -1104,7 +1102,7 @@ static int Seek( demux_t *p_demux, mtime_t i_date, int i_percent )
i_stream
,
p_stream
->
i_idxposc
+
1
)
)
{
msg_Warn
(
p_demux
,
"cannot seek"
);
return
(
-
1
)
;
return
VLC_EGENERIC
;
}
}
...
...
@@ -1148,12 +1146,12 @@ static int Seek( demux_t *p_demux, mtime_t i_date, int i_percent )
p_sys
->
i_time
=
i_date
;
}
#undef p_stream
return
(
1
)
;
return
VLC_SUCCESS
;
}
else
{
msg_Err
(
p_demux
,
"shouldn't yet be executed"
);
return
(
-
1
)
;
return
VLC_EGENERIC
;
}
}
...
...
@@ -1214,7 +1212,7 @@ static int Control( demux_t *p_demux, int i_query, va_list args )
if
(
p_sys
->
b_seekable
)
{
i64
=
(
mtime_t
)(
1000000
.
0
*
p_sys
->
i_length
*
f
);
return
Seek
(
p_demux
,
i64
,
(
int
)(
f
*
100
)
)
<
0
?
VLC_EGENERIC
:
VLC_SUCCESS
;
return
Seek
(
p_demux
,
i64
,
(
int
)(
f
*
100
)
);
}
else
{
...
...
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