Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
L
libdvbpsi
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
libdvbpsi
Commits
9a5a4fa0
Commit
9a5a4fa0
authored
Mar 28, 2011
by
Jean-Paul Saman
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
src/dvbpsi.c: dvbpsi_PushPacket() sanity checking
parent
dd6d44b5
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
3 deletions
+8
-3
src/dvbpsi.c
src/dvbpsi.c
+8
-3
No files found.
src/dvbpsi.c
View file @
9a5a4fa0
...
...
@@ -225,7 +225,6 @@ bool dvbpsi_PushPacket(dvbpsi_t *handle, uint8_t* p_data)
dvbpsi_decoder_t
*
p_decoder
=
(
dvbpsi_decoder_t
*
)
handle
->
p_private
;
assert
(
p_decoder
);
assert
(
p_decoder
->
pf_callback
);
/* TS start code */
if
(
p_data
[
0
]
!=
0x47
)
...
...
@@ -297,6 +296,8 @@ bool dvbpsi_PushPacket(dvbpsi_t *handle, uint8_t* p_data)
p_decoder
->
p_current_section
=
p_section
=
dvbpsi_NewPSISection
(
p_decoder
->
i_section_max_size
);
if
(
!
p_section
)
return
false
;
/* Update the position in the packet */
p_payload_pos
=
p_new_pos
;
/* New section is being handled */
...
...
@@ -347,6 +348,8 @@ bool dvbpsi_PushPacket(dvbpsi_t *handle, uint8_t* p_data)
p_decoder
->
p_current_section
=
p_section
=
dvbpsi_NewPSISection
(
p_decoder
->
i_section_max_size
);
if
(
!
p_section
)
return
false
;
p_payload_pos
=
p_new_pos
;
p_new_pos
=
NULL
;
p_decoder
->
i_need
=
3
;
...
...
@@ -391,8 +394,8 @@ bool dvbpsi_PushPacket(dvbpsi_t *handle, uint8_t* p_data)
p_section
->
i_last_number
=
0
;
p_section
->
p_payload_start
=
p_section
->
p_data
+
3
;
}
p_decoder
->
pf_callback
(
handle
,
p_section
);
if
(
p_decoder
->
pf_callback
)
p_decoder
->
pf_callback
(
handle
,
p_section
);
p_decoder
->
p_current_section
=
NULL
;
}
else
...
...
@@ -417,6 +420,8 @@ bool dvbpsi_PushPacket(dvbpsi_t *handle, uint8_t* p_data)
p_decoder
->
p_current_section
=
p_section
=
dvbpsi_NewPSISection
(
p_decoder
->
i_section_max_size
);
if
(
!
p_section
)
return
false
;
p_payload_pos
=
p_new_pos
;
p_new_pos
=
NULL
;
p_decoder
->
i_need
=
3
;
...
...
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