Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc
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
Commits
67c077de
Commit
67c077de
authored
Sep 03, 2008
by
Rémi Denis-Courmont
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Signals: only one thread needed now
parent
6ba83343
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
23 deletions
+4
-23
modules/control/signals.c
modules/control/signals.c
+4
-23
No files found.
modules/control/signals.c
View file @
67c077de
...
@@ -31,7 +31,6 @@
...
@@ -31,7 +31,6 @@
static
int
Open
(
vlc_object_t
*
);
static
int
Open
(
vlc_object_t
*
);
static
void
Close
(
vlc_object_t
*
);
static
void
Close
(
vlc_object_t
*
);
static
void
Run
(
intf_thread_t
*
);
static
void
*
SigThread
(
void
*
);
static
void
*
SigThread
(
void
*
);
vlc_module_begin
();
vlc_module_begin
();
...
@@ -67,7 +66,7 @@ static int Open (vlc_object_t *obj)
...
@@ -67,7 +66,7 @@ static int Open (vlc_object_t *obj)
return
VLC_ENOMEM
;
return
VLC_ENOMEM
;
}
}
intf
->
pf_run
=
Run
;
intf
->
pf_run
=
NULL
;
return
0
;
return
0
;
}
}
...
@@ -113,21 +112,7 @@ static void *SigThread (void *data)
...
@@ -113,21 +112,7 @@ static void *SigThread (void *data)
vlc_testcancel
();
vlc_testcancel
();
#endif
#endif
vlc_object_lock
(
obj
);
switch
(
signum
)
p_sys
->
signum
=
signum
;
vlc_object_signal_unlocked
(
obj
);
vlc_object_unlock
(
obj
);
}
}
static
void
Run
(
intf_thread_t
*
obj
)
{
intf_sys_t
*
p_sys
=
obj
->
p_sys
;
vlc_object_lock
(
obj
);
while
(
vlc_object_alive
(
obj
))
{
switch
(
p_sys
->
signum
)
{
{
case
SIGINT
:
case
SIGINT
:
case
SIGHUP
:
case
SIGHUP
:
...
@@ -135,12 +120,8 @@ static void Run (intf_thread_t *obj)
...
@@ -135,12 +120,8 @@ static void Run (intf_thread_t *obj)
case
SIGQUIT
:
case
SIGQUIT
:
msg_Err
(
obj
,
"Caught %s signal, exiting..."
,
msg_Err
(
obj
,
"Caught %s signal, exiting..."
,
strsignal
(
p_sys
->
signum
));
strsignal
(
p_sys
->
signum
));
goto
out
;
vlc_object_kill
(
obj
->
p_libvlc
);
break
;
}
}
vlc_object_wait
(
obj
);
}
}
out:
vlc_object_unlock
(
obj
);
vlc_object_kill
(
obj
->
p_libvlc
);
}
}
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