Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-2-2
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-2-2
Commits
6b822f38
Commit
6b822f38
authored
Dec 09, 2007
by
Rémi Denis-Courmont
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Use (s)size_t for pf_read and pf_write.
This is very likely to break .*64 platforms.
parent
2d40161c
Changes
21
Hide whitespace changes
Inline
Side-by-side
Showing
21 changed files
with
54 additions
and
65 deletions
+54
-65
include/vlc_access.h
include/vlc_access.h
+1
-1
include/vlc_sout.h
include/vlc_sout.h
+4
-4
modules/access/cdda/access.c
modules/access/cdda/access.c
+1
-1
modules/access/directory.c
modules/access/directory.c
+5
-5
modules/access/eyetv.c
modules/access/eyetv.c
+2
-2
modules/access/file.c
modules/access/file.c
+2
-2
modules/access/ftp.c
modules/access/ftp.c
+4
-4
modules/access/http.c
modules/access/http.c
+2
-2
modules/access/mms/mmsh.c
modules/access/mms/mmsh.c
+6
-6
modules/access/mms/mmstu.c
modules/access/mms/mmstu.c
+2
-2
modules/access/pvr.c
modules/access/pvr.c
+2
-2
modules/access/smb.c
modules/access/smb.c
+2
-2
modules/access/tcp.c
modules/access/tcp.c
+2
-2
modules/access_filter/bandwidth.c
modules/access_filter/bandwidth.c
+2
-2
modules/access_filter/dump.c
modules/access_filter/dump.c
+2
-2
modules/access_filter/record.c
modules/access_filter/record.c
+2
-2
modules/access_output/file.c
modules/access_output/file.c
+4
-4
modules/access_output/http.c
modules/access_output/http.c
+2
-2
modules/access_output/shout.c
modules/access_output/shout.c
+2
-13
modules/access_output/udp.c
modules/access_output/udp.c
+2
-2
src/stream_output/stream_output.c
src/stream_output/stream_output.c
+3
-3
No files found.
include/vlc_access.h
View file @
6b822f38
...
...
@@ -88,7 +88,7 @@ struct access_t
/* pf_read/pf_block is used to read data.
* XXX A access should set one and only one of them */
int
(
*
pf_read
)
(
access_t
*
,
uint8_t
*
,
in
t
);
/* Return -1 if no data yet, 0 if no more data, else real data read */
ssize_t
(
*
pf_read
)
(
access_t
*
,
uint8_t
*
,
size_
t
);
/* Return -1 if no data yet, 0 if no more data, else real data read */
block_t
*
(
*
pf_block
)(
access_t
*
);
/* return a block of data in his 'natural' size, NULL if not yet data or eof */
/* Called for each seek.
...
...
include/vlc_sout.h
View file @
6b822f38
...
...
@@ -93,8 +93,8 @@ struct sout_access_out_t
char
*
psz_path
;
sout_access_out_sys_t
*
p_sys
;
int
(
*
pf_seek
)(
sout_access_out_t
*
,
off_t
);
int
(
*
pf_read
)(
sout_access_out_t
*
,
block_t
*
);
int
(
*
pf_write
)(
sout_access_out_t
*
,
block_t
*
);
ssize_t
(
*
pf_read
)(
sout_access_out_t
*
,
block_t
*
);
ssize_t
(
*
pf_write
)(
sout_access_out_t
*
,
block_t
*
);
int
(
*
pf_control
)(
sout_access_out_t
*
,
int
,
va_list
);
config_chain_t
*
p_cfg
;
...
...
@@ -104,8 +104,8 @@ struct sout_access_out_t
VLC_EXPORT
(
sout_access_out_t
*
,
sout_AccessOutNew
,
(
sout_instance_t
*
,
const
char
*
psz_access
,
const
char
*
psz_name
)
);
VLC_EXPORT
(
void
,
sout_AccessOutDelete
,
(
sout_access_out_t
*
)
);
VLC_EXPORT
(
int
,
sout_AccessOutSeek
,
(
sout_access_out_t
*
,
off_t
)
);
VLC_EXPORT
(
int
,
sout_AccessOutRead
,
(
sout_access_out_t
*
,
block_t
*
)
);
VLC_EXPORT
(
int
,
sout_AccessOutWrite
,
(
sout_access_out_t
*
,
block_t
*
)
);
VLC_EXPORT
(
ssize_t
,
sout_AccessOutRead
,
(
sout_access_out_t
*
,
block_t
*
)
);
VLC_EXPORT
(
ssize_t
,
sout_AccessOutWrite
,
(
sout_access_out_t
*
,
block_t
*
)
);
VLC_EXPORT
(
int
,
sout_AccessOutControl
,(
sout_access_out_t
*
,
int
,
va_list
)
);
/** Muxer structure */
...
...
modules/access/cdda/access.c
View file @
6b822f38
...
...
@@ -55,7 +55,7 @@ access_t *p_cdda_input = NULL;
/*****************************************************************************
* Local prototypes
*****************************************************************************/
static
int
CDDARead
(
access_t
*
,
uint8_t
*
,
in
t
);
static
ssize_t
CDDARead
(
access_t
*
,
uint8_t
*
,
size_
t
);
static
block_t
*
CDDAReadBlocks
(
access_t
*
p_access
);
static
int
CDDASeek
(
access_t
*
p_access
,
int64_t
i_pos
);
static
int
CDDAControl
(
access_t
*
p_access
,
int
i_query
,
...
...
modules/access/directory.c
View file @
6b822f38
...
...
@@ -121,8 +121,8 @@ enum
typedef
struct
stat_list_t
stat_list_t
;
static
int
Read
(
access_t
*
,
uint8_t
*
,
in
t
);
static
int
ReadNull
(
access_t
*
,
uint8_t
*
,
in
t
);
static
ssize_t
Read
(
access_t
*
,
uint8_t
*
,
size_
t
);
static
ssize_t
ReadNull
(
access_t
*
,
uint8_t
*
,
size_
t
);
static
int
Control
(
access_t
*
,
int
,
va_list
);
static
int
Demux
(
demux_t
*
p_demux
);
...
...
@@ -172,7 +172,7 @@ static void Close( vlc_object_t * p_this )
/*****************************************************************************
* ReadNull: read the directory
*****************************************************************************/
static
int
ReadNull
(
access_t
*
p_access
,
uint8_t
*
p_buffer
,
in
t
i_len
)
static
ssize_t
ReadNull
(
access_t
*
p_access
,
uint8_t
*
p_buffer
,
size_
t
i_len
)
{
/* Return fake data */
memset
(
p_buffer
,
0
,
i_len
);
...
...
@@ -182,7 +182,7 @@ static int ReadNull( access_t *p_access, uint8_t *p_buffer, int i_len)
/*****************************************************************************
* Read: read the directory
*****************************************************************************/
static
int
Read
(
access_t
*
p_access
,
uint8_t
*
p_buffer
,
in
t
i_len
)
static
ssize_t
Read
(
access_t
*
p_access
,
uint8_t
*
p_buffer
,
size_
t
i_len
)
{
char
*
psz
;
int
i_mode
,
i_activity
;
...
...
@@ -261,7 +261,7 @@ static int Read( access_t *p_access, uint8_t *p_buffer, int i_len)
/* Return fake data forever */
p_access
->
pf_read
=
ReadNull
;
return
ReadNull
(
p_access
,
p_buffer
,
i_len
)
;
return
-
1
;
}
/*****************************************************************************
...
...
modules/access/eyetv.c
View file @
6b822f38
...
...
@@ -72,7 +72,7 @@ CFDataRef dataFromEyetv;
int
lastPacketId
;
int
lastForwardedPacketId
;
static
int
Read
(
access_t
*
,
uint8_t
*
,
in
t
);
static
ssize_t
Read
(
access_t
*
,
uint8_t
*
,
size_
t
);
static
int
Control
(
access_t
*
,
int
,
va_list
);
static
void
Thread
(
vlc_object_t
*
);
CFDataRef
msgPortCallback
(
CFMessagePortRef
local
,
SInt32
msgid
,
CFDataRef
data
,
void
*
info
);
...
...
@@ -240,7 +240,7 @@ CFDataRef msgPortCallback( CFMessagePortRef local, SInt32 msgid, CFDataRef data,
/*****************************************************************************
* Read: forwarding data from EyeTV plugin which was received above
*****************************************************************************/
static
int
Read
(
access_t
*
p_access
,
uint8_t
*
p_buffer
,
in
t
i_len
)
static
ssize_t
Read
(
access_t
*
p_access
,
uint8_t
*
p_buffer
,
size_
t
i_len
)
{
access_sys_t
*
p_sys
=
p_access
->
p_sys
;
extern
CFDataRef
dataFromEyetv
;
...
...
modules/access/file.c
View file @
6b822f38
...
...
@@ -106,7 +106,7 @@ vlc_module_end();
* Exported prototypes
*****************************************************************************/
static
int
Seek
(
access_t
*
,
int64_t
);
static
int
Read
(
access_t
*
,
uint8_t
*
,
in
t
);
static
ssize_t
Read
(
access_t
*
,
uint8_t
*
,
size_
t
);
static
int
Control
(
access_t
*
,
int
,
va_list
);
static
block_t
*
mmapBlock
(
access_t
*
);
...
...
@@ -249,7 +249,7 @@ static void Close (vlc_object_t * p_this)
/*****************************************************************************
* Read: standard read on a file descriptor.
*****************************************************************************/
static
int
Read
(
access_t
*
p_access
,
uint8_t
*
p_buffer
,
in
t
i_len
)
static
ssize_t
Read
(
access_t
*
p_access
,
uint8_t
*
p_buffer
,
size_
t
i_len
)
{
access_sys_t
*
p_sys
=
p_access
->
p_sys
;
int
i_ret
;
...
...
modules/access/ftp.c
View file @
6b822f38
...
...
@@ -92,8 +92,8 @@ vlc_module_end();
/*****************************************************************************
* Local prototypes
*****************************************************************************/
static
int
Read
(
access_t
*
,
uint8_t
*
,
in
t
);
static
in
t
Write
(
sout_access_out_t
*
,
block_t
*
);
static
ssize_t
Read
(
access_t
*
,
uint8_t
*
,
size_
t
);
static
ssize_
t
Write
(
sout_access_out_t
*
,
block_t
*
);
static
int
Seek
(
access_t
*
,
int64_t
);
static
int
OutSeek
(
sout_access_out_t
*
,
int64_t
);
static
int
Control
(
access_t
*
,
int
,
va_list
);
...
...
@@ -461,7 +461,7 @@ static int OutSeek( sout_access_out_t *p_access, off_t i_pos )
/*****************************************************************************
* Read:
*****************************************************************************/
static
int
Read
(
access_t
*
p_access
,
uint8_t
*
p_buffer
,
in
t
i_len
)
static
ssize_t
Read
(
access_t
*
p_access
,
uint8_t
*
p_buffer
,
size_
t
i_len
)
{
access_sys_t
*
p_sys
=
p_access
->
p_sys
;
int
i_read
;
...
...
@@ -485,7 +485,7 @@ static int Read( access_t *p_access, uint8_t *p_buffer, int i_len )
/*****************************************************************************
* Write:
*****************************************************************************/
static
in
t
Write
(
sout_access_out_t
*
p_access
,
block_t
*
p_buffer
)
static
ssize_
t
Write
(
sout_access_out_t
*
p_access
,
block_t
*
p_buffer
)
{
access_sys_t
*
p_sys
=
GET_OUT_SYS
(
p_access
);
size_t
i_write
=
0
;
...
...
modules/access/http.c
View file @
6b822f38
...
...
@@ -143,7 +143,7 @@ struct access_sys_t
};
/* */
static
int
Read
(
access_t
*
,
uint8_t
*
,
in
t
);
static
ssize_t
Read
(
access_t
*
,
uint8_t
*
,
size_
t
);
static
int
Seek
(
access_t
*
,
int64_t
);
static
int
Control
(
access_t
*
,
int
,
va_list
);
...
...
@@ -459,7 +459,7 @@ static void Close( vlc_object_t *p_this )
* p_buffer. Return the actual number of bytes read
*****************************************************************************/
static
int
ReadICYMeta
(
access_t
*
p_access
);
static
int
Read
(
access_t
*
p_access
,
uint8_t
*
p_buffer
,
in
t
i_len
)
static
ssize_t
Read
(
access_t
*
p_access
,
uint8_t
*
p_buffer
,
size_
t
i_len
)
{
access_sys_t
*
p_sys
=
p_access
->
p_sys
;
int
i_read
;
...
...
modules/access/mms/mmsh.c
View file @
6b822f38
...
...
@@ -48,8 +48,8 @@
int
E_
(
MMSHOpen
)
(
access_t
*
);
void
E_
(
MMSHClose
)
(
access_t
*
);
static
int
Read
(
access_t
*
,
uint8_t
*
,
in
t
);
static
int
ReadRedirect
(
access_t
*
,
uint8_t
*
,
in
t
);
static
ssize_t
Read
(
access_t
*
,
uint8_t
*
,
size_
t
);
static
ssize_t
ReadRedirect
(
access_t
*
,
uint8_t
*
,
size_
t
);
static
int
Seek
(
access_t
*
,
int64_t
);
static
int
Control
(
access_t
*
,
int
,
va_list
);
...
...
@@ -338,22 +338,22 @@ static int Seek( access_t *p_access, int64_t i_pos )
/*****************************************************************************
* Read:
*****************************************************************************/
static
int
ReadRedirect
(
access_t
*
p_access
,
uint8_t
*
p
,
in
t
i_len
)
static
ssize_t
ReadRedirect
(
access_t
*
p_access
,
uint8_t
*
p
,
size_
t
i_len
)
{
return
VLC_SUCCESS
;
return
0
;
}
/*****************************************************************************
* Read:
*****************************************************************************/
static
int
Read
(
access_t
*
p_access
,
uint8_t
*
p_buffer
,
in
t
i_len
)
static
ssize_t
Read
(
access_t
*
p_access
,
uint8_t
*
p_buffer
,
size_
t
i_len
)
{
access_sys_t
*
p_sys
=
p_access
->
p_sys
;
size_t
i_copy
;
size_t
i_data
=
0
;
if
(
p_access
->
info
.
b_eof
)
return
VLC_SUCCESS
;
return
0
;
while
(
i_data
<
(
size_t
)
i_len
)
{
...
...
modules/access/mms/mmstu.c
View file @
6b822f38
...
...
@@ -68,7 +68,7 @@ int E_( MMSTUOpen ) ( access_t * );
void
E_
(
MMSTUClose
)
(
access_t
*
);
static
int
Read
(
access_t
*
,
uint8_t
*
,
in
t
);
static
ssize_t
Read
(
access_t
*
,
uint8_t
*
,
size_
t
);
static
int
Seek
(
access_t
*
,
int64_t
);
static
int
Control
(
access_t
*
,
int
,
va_list
);
...
...
@@ -370,7 +370,7 @@ static int Seek( access_t * p_access, int64_t i_pos )
/*****************************************************************************
* Read:
*****************************************************************************/
static
int
Read
(
access_t
*
p_access
,
uint8_t
*
p_buffer
,
in
t
i_len
)
static
ssize_t
Read
(
access_t
*
p_access
,
uint8_t
*
p_buffer
,
size_
t
i_len
)
{
access_sys_t
*
p_sys
=
p_access
->
p_sys
;
size_t
i_data
;
...
...
modules/access/pvr.c
View file @
6b822f38
...
...
@@ -166,7 +166,7 @@ vlc_module_end();
/*****************************************************************************
* Prototypes
*****************************************************************************/
static
int
Read
(
access_t
*
,
uint8_t
*
,
in
t
);
static
ssize_t
Read
(
access_t
*
,
uint8_t
*
,
size_
t
);
static
int
Control
(
access_t
*
,
int
,
va_list
);
/* ivtv specific ioctls */
...
...
@@ -1063,7 +1063,7 @@ static void Close( vlc_object_t * p_this )
/*****************************************************************************
* Read
*****************************************************************************/
static
int
Read
(
access_t
*
p_access
,
uint8_t
*
p_buffer
,
in
t
i_len
)
static
ssize_t
Read
(
access_t
*
p_access
,
uint8_t
*
p_buffer
,
size_
t
i_len
)
{
access_sys_t
*
p_sys
=
(
access_sys_t
*
)
p_access
->
p_sys
;
struct
pollfd
ufd
;
...
...
modules/access/smb.c
View file @
6b822f38
...
...
@@ -91,7 +91,7 @@ vlc_module_end();
/*****************************************************************************
* Local prototypes
*****************************************************************************/
static
int
Read
(
access_t
*
,
uint8_t
*
,
in
t
);
static
ssize_t
Read
(
access_t
*
,
uint8_t
*
,
size_
t
);
static
int
Seek
(
access_t
*
,
int64_t
);
static
int
Control
(
access_t
*
,
int
,
va_list
);
...
...
@@ -348,7 +348,7 @@ static int Seek( access_t *p_access, int64_t i_pos )
/*****************************************************************************
* Read:
*****************************************************************************/
static
int
Read
(
access_t
*
p_access
,
uint8_t
*
p_buffer
,
in
t
i_len
)
static
ssize_t
Read
(
access_t
*
p_access
,
uint8_t
*
p_buffer
,
size_
t
i_len
)
{
access_sys_t
*
p_sys
=
p_access
->
p_sys
;
int
i_read
;
...
...
modules/access/tcp.c
View file @
6b822f38
...
...
@@ -64,7 +64,7 @@ struct access_sys_t
};
static
int
Read
(
access_t
*
,
uint8_t
*
,
in
t
);
static
ssize_t
Read
(
access_t
*
,
uint8_t
*
,
size_
t
);
static
int
Control
(
access_t
*
,
int
,
va_list
);
/*****************************************************************************
...
...
@@ -132,7 +132,7 @@ static void Close( vlc_object_t *p_this )
/*****************************************************************************
* Read: read on a file descriptor, checking b_die periodically
*****************************************************************************/
static
int
Read
(
access_t
*
p_access
,
uint8_t
*
p_buffer
,
in
t
i_len
)
static
ssize_t
Read
(
access_t
*
p_access
,
uint8_t
*
p_buffer
,
size_
t
i_len
)
{
access_sys_t
*
p_sys
=
p_access
->
p_sys
;
int
i_read
;
...
...
modules/access_filter/bandwidth.c
View file @
6b822f38
...
...
@@ -49,7 +49,7 @@ vlc_module_begin ();
BANDWIDTH_LONGTEXT
,
VLC_FALSE
);
vlc_module_end
();
static
int
Read
(
access_t
*
access
,
uint8_t
*
buffer
,
in
t
len
);
static
ssize_t
Read
(
access_t
*
access
,
uint8_t
*
buffer
,
size_
t
len
);
static
int
Seek
(
access_t
*
access
,
int64_t
offset
);
static
int
Control
(
access_t
*
access
,
int
cmd
,
va_list
ap
);
...
...
@@ -107,7 +107,7 @@ static void Close (vlc_object_t *obj)
}
static
int
Read
(
access_t
*
access
,
uint8_t
*
buffer
,
in
t
len
)
static
ssize_t
Read
(
access_t
*
access
,
uint8_t
*
buffer
,
size_
t
len
)
{
access_t
*
src
=
access
->
p_source
;
access_sys_t
*
p_sys
=
access
->
p_sys
;
...
...
modules/access_filter/dump.c
View file @
6b822f38
...
...
@@ -60,7 +60,7 @@ vlc_module_begin ();
MARGIN_LONGTEXT
,
VLC_FALSE
);
vlc_module_end
();
static
int
Read
(
access_t
*
access
,
uint8_t
*
buffer
,
in
t
len
);
static
ssize_t
Read
(
access_t
*
access
,
uint8_t
*
buffer
,
size_
t
len
);
static
block_t
*
Block
(
access_t
*
access
);
static
int
Seek
(
access_t
*
access
,
int64_t
offset
);
static
int
Control
(
access_t
*
access
,
int
cmd
,
va_list
ap
);
...
...
@@ -180,7 +180,7 @@ error:
}
static
int
Read
(
access_t
*
access
,
uint8_t
*
buffer
,
in
t
len
)
static
ssize_t
Read
(
access_t
*
access
,
uint8_t
*
buffer
,
size_
t
len
)
{
access_t
*
src
=
access
->
p_source
;
...
...
modules/access_filter/record.c
View file @
6b822f38
...
...
@@ -67,7 +67,7 @@ vlc_module_end();
*****************************************************************************/
static
block_t
*
Block
(
access_t
*
);
static
int
Read
(
access_t
*
,
uint8_t
*
,
in
t
);
static
ssize_t
Read
(
access_t
*
,
uint8_t
*
,
size_
t
);
static
int
Control
(
access_t
*
,
int
i_query
,
va_list
args
);
static
int
Seek
(
access_t
*
,
int64_t
);
...
...
@@ -205,7 +205,7 @@ static block_t *Block( access_t *p_access )
/*****************************************************************************
*
*****************************************************************************/
static
int
Read
(
access_t
*
p_access
,
uint8_t
*
p_buffer
,
in
t
i_len
)
static
ssize_t
Read
(
access_t
*
p_access
,
uint8_t
*
p_buffer
,
size_
t
i_len
)
{
access_t
*
p_src
=
p_access
->
p_source
;
int
i_ret
;
...
...
modules/access_output/file.c
View file @
6b822f38
...
...
@@ -83,9 +83,9 @@ static const char *ppsz_sout_options[] = {
"append"
,
NULL
};
static
in
t
Write
(
sout_access_out_t
*
,
block_t
*
);
static
ssize_
t
Write
(
sout_access_out_t
*
,
block_t
*
);
static
int
Seek
(
sout_access_out_t
*
,
off_t
);
static
in
t
Read
(
sout_access_out_t
*
,
block_t
*
);
static
ssize_
t
Read
(
sout_access_out_t
*
,
block_t
*
);
struct
sout_access_out_sys_t
{
...
...
@@ -184,7 +184,7 @@ static void Close( vlc_object_t * p_this )
/*****************************************************************************
* Read: standard read on a file descriptor.
*****************************************************************************/
static
in
t
Read
(
sout_access_out_t
*
p_access
,
block_t
*
p_buffer
)
static
ssize_
t
Read
(
sout_access_out_t
*
p_access
,
block_t
*
p_buffer
)
{
if
(
strcmp
(
p_access
->
psz_path
,
"-"
)
)
{
...
...
@@ -199,7 +199,7 @@ static int Read( sout_access_out_t *p_access, block_t *p_buffer )
/*****************************************************************************
* Write: standard write on a file descriptor.
*****************************************************************************/
static
in
t
Write
(
sout_access_out_t
*
p_access
,
block_t
*
p_buffer
)
static
ssize_
t
Write
(
sout_access_out_t
*
p_access
,
block_t
*
p_buffer
)
{
size_t
i_write
=
0
;
...
...
modules/access_output/http.c
View file @
6b822f38
...
...
@@ -122,7 +122,7 @@ static const char *ppsz_sout_options[] = {
"user"
,
"pwd"
,
"mime"
,
"cert"
,
"key"
,
"ca"
,
"crl"
,
NULL
};
static
in
t
Write
(
sout_access_out_t
*
,
block_t
*
);
static
ssize_
t
Write
(
sout_access_out_t
*
,
block_t
*
);
static
int
Seek
(
sout_access_out_t
*
,
off_t
);
struct
sout_access_out_sys_t
...
...
@@ -373,7 +373,7 @@ static void Close( vlc_object_t * p_this )
/*****************************************************************************
* Write:
*****************************************************************************/
static
in
t
Write
(
sout_access_out_t
*
p_access
,
block_t
*
p_buffer
)
static
ssize_
t
Write
(
sout_access_out_t
*
p_access
,
block_t
*
p_buffer
)
{
sout_access_out_sys_t
*
p_sys
=
p_access
->
p_sys
;
int
i_err
=
0
;
...
...
modules/access_output/shout.c
View file @
6b822f38
...
...
@@ -144,9 +144,8 @@ static const char *ppsz_sout_options[] = {
/*****************************************************************************
* Exported prototypes
*****************************************************************************/
static
in
t
Write
(
sout_access_out_t
*
,
block_t
*
);
static
ssize_
t
Write
(
sout_access_out_t
*
,
block_t
*
);
static
int
Seek
(
sout_access_out_t
*
,
off_t
);
static
int
Read
(
sout_access_out_t
*
,
block_t
*
);
struct
sout_access_out_sys_t
{
...
...
@@ -445,7 +444,6 @@ static int Open( vlc_object_t *p_this )
}
p_access
->
pf_write
=
Write
;
p_access
->
pf_read
=
Read
;
p_access
->
pf_seek
=
Seek
;
msg_Dbg
(
p_access
,
"shout access output opened (%s@%s:%i/%s)"
,
...
...
@@ -485,19 +483,10 @@ static void Close( vlc_object_t * p_this )
msg_Dbg
(
p_access
,
"shout access output closed"
);
}
/*****************************************************************************
* Read: standard read -- not supported
*****************************************************************************/
static
int
Read
(
sout_access_out_t
*
p_access
,
block_t
*
p_buffer
)
{
msg_Err
(
p_access
,
"cannot read from shout"
);
return
VLC_EGENERIC
;
}
/*****************************************************************************
* Write: standard write
*****************************************************************************/
static
in
t
Write
(
sout_access_out_t
*
p_access
,
block_t
*
p_buffer
)
static
ssize_
t
Write
(
sout_access_out_t
*
p_access
,
block_t
*
p_buffer
)
{
size_t
i_write
=
0
;
...
...
modules/access_output/udp.c
View file @
6b822f38
...
...
@@ -112,7 +112,7 @@ static const char *const ppsz_core_options[] = {
NULL
};
static
int
Write
(
sout_access_out_t
*
,
block_t
*
);
static
ssize_t
Write
(
sout_access_out_t
*
,
block_t
*
);
static
int
Seek
(
sout_access_out_t
*
,
off_t
);
static
void
ThreadWrite
(
vlc_object_t
*
);
...
...
@@ -323,7 +323,7 @@ static void Close( vlc_object_t * p_this )
/*****************************************************************************
* Write: standard write on a file descriptor.
*****************************************************************************/
static
in
t
Write
(
sout_access_out_t
*
p_access
,
block_t
*
p_buffer
)
static
ssize_
t
Write
(
sout_access_out_t
*
p_access
,
block_t
*
p_buffer
)
{
sout_access_out_sys_t
*
p_sys
=
p_access
->
p_sys
;
int
i_len
=
0
;
...
...
src/stream_output/stream_output.c
View file @
6b822f38
...
...
@@ -365,7 +365,7 @@ int sout_AccessOutSeek( sout_access_out_t *p_access, off_t i_pos )
/*****************************************************************************
* sout_AccessRead:
*****************************************************************************/
in
t
sout_AccessOutRead
(
sout_access_out_t
*
p_access
,
block_t
*
p_buffer
)
ssize_
t
sout_AccessOutRead
(
sout_access_out_t
*
p_access
,
block_t
*
p_buffer
)
{
return
(
p_access
->
pf_read
?
p_access
->
pf_read
(
p_access
,
p_buffer
)
:
VLC_EGENERIC
);
...
...
@@ -374,9 +374,9 @@ int sout_AccessOutRead( sout_access_out_t *p_access, block_t *p_buffer )
/*****************************************************************************
* sout_AccessWrite:
*****************************************************************************/
in
t
sout_AccessOutWrite
(
sout_access_out_t
*
p_access
,
block_t
*
p_buffer
)
ssize_
t
sout_AccessOutWrite
(
sout_access_out_t
*
p_access
,
block_t
*
p_buffer
)
{
const
int
i_packets_gather
=
30
;
const
unsigned
i_packets_gather
=
30
;
p_access
->
i_writes
++
;
p_access
->
i_sent_bytes
+=
p_buffer
->
i_buffer
;
if
(
(
p_access
->
i_writes
%
i_packets_gather
)
==
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