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
dde85414
Commit
dde85414
authored
Aug 12, 2008
by
Rémi Denis-Courmont
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
UDP access_out: get rid of block_FifoWake and blocking mwait()
parent
3f8d9536
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
11 deletions
+5
-11
modules/access_output/udp.c
modules/access_output/udp.c
+5
-11
No files found.
modules/access_output/udp.c
View file @
dde85414
...
@@ -280,7 +280,6 @@ static void Close( vlc_object_t * p_this )
...
@@ -280,7 +280,6 @@ static void Close( vlc_object_t * p_this )
int
i
;
int
i
;
vlc_object_kill
(
p_sys
->
p_thread
);
vlc_object_kill
(
p_sys
->
p_thread
);
block_FifoWake
(
p_sys
->
p_thread
->
p_fifo
);
for
(
i
=
0
;
i
<
10
;
i
++
)
for
(
i
=
0
;
i
<
10
;
i
++
)
{
{
...
@@ -443,9 +442,8 @@ static void* ThreadWrite( vlc_object_t *p_this )
...
@@ -443,9 +442,8 @@ static void* ThreadWrite( vlc_object_t *p_this )
mtime_t
i_date_last
=
-
1
;
mtime_t
i_date_last
=
-
1
;
mtime_t
i_to_send
=
p_thread
->
i_group
;
mtime_t
i_to_send
=
p_thread
->
i_group
;
int
i_dropped_packets
=
0
;
int
i_dropped_packets
=
0
;
int
canc
=
vlc_savecancel
();
while
(
vlc_object_alive
(
p_thread
)
)
for
(;;
)
{
{
block_t
*
p_pk
;
block_t
*
p_pk
;
mtime_t
i_date
,
i_sent
;
mtime_t
i_date
,
i_sent
;
...
@@ -462,8 +460,6 @@ static void* ThreadWrite( vlc_object_t *p_this )
...
@@ -462,8 +460,6 @@ static void* ThreadWrite( vlc_object_t *p_this )
}
}
#endif
#endif
p_pk
=
block_FifoGet
(
p_thread
->
p_fifo
);
p_pk
=
block_FifoGet
(
p_thread
->
p_fifo
);
if
(
p_pk
==
NULL
)
continue
;
/* forced wake-up */
i_date
=
p_thread
->
i_caching
+
p_pk
->
i_dts
;
i_date
=
p_thread
->
i_caching
+
p_pk
->
i_dts
;
if
(
i_date_last
>
0
)
if
(
i_date_last
>
0
)
...
@@ -488,18 +484,17 @@ static void* ThreadWrite( vlc_object_t *p_this )
...
@@ -488,18 +484,17 @@ static void* ThreadWrite( vlc_object_t *p_this )
}
}
}
}
block_cleanup_push
(
p_pk
);
i_to_send
--
;
i_to_send
--
;
if
(
!
i_to_send
||
(
p_pk
->
i_flags
&
BLOCK_FLAG_CLOCK
)
)
if
(
!
i_to_send
||
(
p_pk
->
i_flags
&
BLOCK_FLAG_CLOCK
)
)
{
{
mwait
(
i_date
);
mwait
(
i_date
);
i_to_send
=
p_thread
->
i_group
;
i_to_send
=
p_thread
->
i_group
;
}
}
ssize_t
val
=
send
(
p_thread
->
i_handle
,
p_pk
->
p_buffer
,
if
(
send
(
p_thread
->
i_handle
,
p_pk
->
p_buffer
,
p_pk
->
i_buffer
,
0
);
p_pk
->
i_buffer
,
0
)
==
-
1
)
if
(
val
==
-
1
)
{
msg_Warn
(
p_thread
,
"send error: %m"
);
msg_Warn
(
p_thread
,
"send error: %m"
);
}
vlc_cleanup_pop
();
if
(
i_dropped_packets
)
if
(
i_dropped_packets
)
{
{
...
@@ -520,6 +515,5 @@ static void* ThreadWrite( vlc_object_t *p_this )
...
@@ -520,6 +515,5 @@ static void* ThreadWrite( vlc_object_t *p_this )
i_date_last
=
i_date
;
i_date_last
=
i_date
;
}
}
vlc_restorecancel
(
canc
);
return
NULL
;
return
NULL
;
}
}
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