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
fddff181
Commit
fddff181
authored
Sep 20, 2008
by
Rémi Denis-Courmont
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Finally remove mis-designed vlc_object_get
parent
670651ee
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
1 addition
and
43 deletions
+1
-43
include/vlc_objects.h
include/vlc_objects.h
+0
-1
src/libvlccore.sym
src/libvlccore.sym
+0
-1
src/misc/objects.c
src/misc/objects.c
+1
-41
No files found.
include/vlc_objects.h
View file @
fddff181
...
...
@@ -82,7 +82,6 @@ VLC_EXPORT( void, __vlc_object_detach, ( vlc_object_t * ) );
#if defined (__GNUC__) && !defined __cplusplus
__attribute__
((
deprecated
))
#endif
VLC_EXPORT
(
void
*
,
vlc_object_get
,
(
libvlc_int_t
*
,
int
)
);
VLC_EXPORT
(
void
*
,
__vlc_object_find
,
(
vlc_object_t
*
,
int
,
int
)
);
VLC_EXPORT
(
vlc_object_t
*
,
vlc_object_find_name
,
(
vlc_object_t
*
,
const
char
*
,
int
)
);
VLC_EXPORT
(
void
,
__vlc_object_yield
,
(
vlc_object_t
*
)
);
...
...
src/libvlccore.sym
View file @
fddff181
...
...
@@ -475,7 +475,6 @@ __vlc_object_create
__vlc_object_detach
__vlc_object_find
vlc_object_find_name
vlc_object_get
__vlc_object_kill
__vlc_object_lock
__vlc_object_release
...
...
src/misc/objects.c
View file @
fddff181
...
...
@@ -514,47 +514,7 @@ void __vlc_object_kill( vlc_object_t *p_this )
}
/**
* Find an object given its ID.
*
* This function looks for the object whose i_object_id field is i_id.
* This function is slow, and often used to hide bugs. Do not use it.
* If you need to retain reference to an object, yield the object pointer with
* vlc_object_yield(), use the pointer as your reference, and call
* vlc_object_release() when you're done.
*/
void
*
vlc_object_get
(
libvlc_int_t
*
p_anchor
,
int
i_id
)
{
vlc_object_t
*
obj
=
NULL
;
#ifndef NDEBUG
int
canc
=
vlc_savecancel
();
fprintf
(
stderr
,
"Use of deprecated vlc_object_get(%d) "
,
i_id
);
vlc_backtrace
();
vlc_restorecancel
(
canc
);
#endif
vlc_mutex_lock
(
&
structure_lock
);
for
(
obj
=
vlc_internals
(
p_anchor
)
->
next
;
obj
!=
VLC_OBJECT
(
p_anchor
);
obj
=
vlc_internals
(
obj
)
->
next
)
{
if
(
obj
->
i_object_id
==
i_id
)
{
vlc_object_yield
(
obj
);
goto
out
;
}
}
obj
=
NULL
;
#ifndef NDEBUG
fprintf
(
stderr
,
"Object %d does not exist
\n
"
,
i_id
);
#endif
out:
vlc_mutex_unlock
(
&
structure_lock
);
return
obj
;
}
/**
****************************************************************************
/*****************************************************************************
* find a typed object and increment its refcount
*****************************************************************************
* This function recursively looks for a given object type. i_mode can be one
...
...
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