Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
D
dvblast
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
dvblast
Commits
309197c4
Commit
309197c4
authored
Dec 28, 2009
by
Marian Ďurkovič
Committed by
Christophe Massiot
Dec 28, 2009
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
* dvb.c: Reuse allocated blocks
parent
cd56127f
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
3 deletions
+4
-3
dvb.c
dvb.c
+4
-3
No files found.
dvb.c
View file @
309197c4
...
@@ -57,6 +57,7 @@ static int i_frontend, i_dvr;
...
@@ -57,6 +57,7 @@ static int i_frontend, i_dvr;
static
fe_status_t
i_last_status
;
static
fe_status_t
i_last_status
;
static
mtime_t
i_frontend_timeout
;
static
mtime_t
i_frontend_timeout
;
static
mtime_t
i_ca_next_event
=
0
;
static
mtime_t
i_ca_next_event
=
0
;
static
block_t
*
p_freelist
=
NULL
;
mtime_t
i_ca_timeout
=
0
;
mtime_t
i_ca_timeout
=
0
;
/*****************************************************************************
/*****************************************************************************
...
@@ -170,13 +171,13 @@ block_t *dvb_Read( void )
...
@@ -170,13 +171,13 @@ block_t *dvb_Read( void )
static
block_t
*
DVRRead
(
void
)
static
block_t
*
DVRRead
(
void
)
{
{
int
i
,
i_len
;
int
i
,
i_len
;
block_t
*
p_ts
,
**
pp_current
=
&
p_ts
;
block_t
*
p_ts
=
p_freelist
,
**
pp_current
=
&
p_ts
;
int
i_read_once
=
output_Count
()
*
NB_BLOCKS
;
int
i_read_once
=
output_Count
()
*
NB_BLOCKS
;
struct
iovec
p_iov
[
i_read_once
];
struct
iovec
p_iov
[
i_read_once
];
for
(
i
=
0
;
i
<
i_read_once
;
i
++
)
for
(
i
=
0
;
i
<
i_read_once
;
i
++
)
{
{
*
pp_current
=
block_New
();
if
(
(
*
pp_current
)
==
NULL
)
*
pp_current
=
block_New
();
p_iov
[
i
].
iov_base
=
(
*
pp_current
)
->
p_ts
;
p_iov
[
i
].
iov_base
=
(
*
pp_current
)
->
p_ts
;
p_iov
[
i
].
iov_len
=
TS_SIZE
;
p_iov
[
i
].
iov_len
=
TS_SIZE
;
pp_current
=
&
(
*
pp_current
)
->
p_next
;
pp_current
=
&
(
*
pp_current
)
->
p_next
;
...
@@ -197,7 +198,7 @@ static block_t *DVRRead( void )
...
@@ -197,7 +198,7 @@ static block_t *DVRRead( void )
i_len
--
;
i_len
--
;
}
}
block_DeleteChain
(
*
pp_current
)
;
p_freelist
=
*
pp_current
;
*
pp_current
=
NULL
;
*
pp_current
=
NULL
;
return
p_ts
;
return
p_ts
;
...
...
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