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
d1d76141
Commit
d1d76141
authored
Sep 19, 2005
by
Gildas Bazin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
* modules/access/rtsp: fixed problem in BlockRead().
parent
6a1a3a70
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
27 additions
and
16 deletions
+27
-16
modules/access/rtsp/access.c
modules/access/rtsp/access.c
+7
-2
modules/access/rtsp/real.c
modules/access/rtsp/real.c
+18
-13
modules/access/rtsp/real.h
modules/access/rtsp/real.h
+2
-1
No files found.
modules/access/rtsp/access.c
View file @
d1d76141
...
...
@@ -259,6 +259,8 @@ static block_t *BlockRead( access_t *p_access )
{
access_sys_t
*
p_sys
=
p_access
->
p_sys
;
block_t
*
p_block
;
rmff_pheader_t
pheader
;
int
i_size
;
if
(
p_sys
->
p_header
)
{
...
...
@@ -267,8 +269,11 @@ static block_t *BlockRead( access_t *p_access )
return
p_block
;
}
p_block
=
block_New
(
p_access
,
4096
);
p_block
->
i_buffer
=
real_get_rdt_chunk
(
p_access
->
p_sys
->
p_rtsp
,
i_size
=
real_get_rdt_chunk_header
(
p_access
->
p_sys
->
p_rtsp
,
&
pheader
);
if
(
i_size
<=
0
)
return
0
;
p_block
=
block_New
(
p_access
,
i_size
);
p_block
->
i_buffer
=
real_get_rdt_chunk
(
p_access
->
p_sys
->
p_rtsp
,
&
pheader
,
&
p_block
->
p_buffer
);
return
p_block
;
...
...
modules/access/rtsp/real.c
View file @
d1d76141
...
...
@@ -532,11 +532,11 @@ rmff_header_t *real_parse_sdp(char *data, char **stream_rules, uint32_t bandwidt
return
header
;
}
int
real_get_rdt_chunk
(
rtsp_client_t
*
rtsp_session
,
unsigned
char
**
buffer
)
{
int
real_get_rdt_chunk_header
(
rtsp_client_t
*
rtsp_session
,
rmff_pheader_t
*
ph
)
{
int
n
=
1
;
uint8_t
header
[
8
];
rmff_pheader_t
ph
;
int
size
;
int
flags1
;
int
unknown1
;
...
...
@@ -582,17 +582,22 @@ int real_get_rdt_chunk(rtsp_client_t *rtsp_session, unsigned char **buffer) {
size
+=
2
;
ph
.
object_version
=
0
;
ph
.
length
=
size
;
ph
.
stream_number
=
(
flags1
>>
1
)
&
1
;
ph
.
timestamp
=
ts
;
ph
.
reserved
=
0
;
ph
.
flags
=
0
;
/* TODO: determine keyframe flag and insert here? */
//xine_buffer_ensure_size(*buffer, 12+size);
rmff_dump_pheader
(
&
ph
,
*
buffer
);
size
-=
12
;
n
=
rtsp_read_data
(
rtsp_session
,
(
*
buffer
)
+
12
,
size
);
ph
->
object_version
=
0
;
ph
->
length
=
size
;
ph
->
stream_number
=
(
flags1
>>
1
)
&
1
;
ph
->
timestamp
=
ts
;
ph
->
reserved
=
0
;
ph
->
flags
=
0
;
/* TODO: determine keyframe flag and insert here? */
return
size
;
}
int
real_get_rdt_chunk
(
rtsp_client_t
*
rtsp_session
,
rmff_pheader_t
*
ph
,
unsigned
char
**
buffer
)
{
int
n
;
rmff_dump_pheader
(
ph
,
*
buffer
);
n
=
rtsp_read_data
(
rtsp_session
,
*
buffer
+
12
,
ph
->
length
-
12
);
return
(
n
<=
0
)
?
0
:
n
+
12
;
}
...
...
modules/access/rtsp/real.h
View file @
d1d76141
...
...
@@ -40,7 +40,8 @@
static
inline
void
lprintf
(
char
*
dummy
,
...
){}
#endif
int
real_get_rdt_chunk
(
rtsp_client_t
*
,
unsigned
char
**
buffer
);
int
real_get_rdt_chunk_header
(
rtsp_client_t
*
,
rmff_pheader_t
*
);
int
real_get_rdt_chunk
(
rtsp_client_t
*
,
rmff_pheader_t
*
,
unsigned
char
**
);
rmff_header_t
*
real_setup_and_get_header
(
rtsp_client_t
*
,
int
bandwidth
);
int
asmrp_match
(
const
char
*
rules
,
int
bandwidth
,
int
*
matches
)
;
...
...
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