Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-gpu
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-gpu
Commits
224742db
Commit
224742db
authored
Aug 15, 2011
by
Rémi Denis-Courmont
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove module_t.psz_object_name
This is the same as module_t.pp_shortcuts[0].
parent
b4f67e40
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
6 additions
and
22 deletions
+6
-22
src/modules/cache.c
src/modules/cache.c
+0
-9
src/modules/entry.c
src/modules/entry.c
+2
-6
src/modules/modules.c
src/modules/modules.c
+4
-6
src/modules/modules.h
src/modules/modules.h
+0
-1
No files found.
src/modules/cache.c
View file @
224742db
...
...
@@ -202,7 +202,6 @@ size_t CacheLoad( vlc_object_t *p_this, const char *dir, module_cache_t **r )
module
=
vlc_module_create
();
/* Load additional infos */
LOAD_STRING
(
module
->
object_name
);
LOAD_STRING
(
module
->
psz_shortname
);
LOAD_STRING
(
module
->
psz_longname
);
LOAD_STRING
(
module
->
psz_help
);
...
...
@@ -210,8 +209,6 @@ size_t CacheLoad( vlc_object_t *p_this, const char *dir, module_cache_t **r )
LOAD_IMMEDIATE
(
module
->
i_shortcuts
);
if
(
module
->
i_shortcuts
>
MODULE_SHORTCUT_MAX
)
goto
error
;
else
if
(
module
->
i_shortcuts
==
0
)
module
->
pp_shortcuts
=
NULL
;
else
{
module
->
pp_shortcuts
=
...
...
@@ -237,9 +234,7 @@ size_t CacheLoad( vlc_object_t *p_this, const char *dir, module_cache_t **r )
while
(
i_submodules
--
)
{
module_t
*
submodule
=
vlc_submodule_create
(
module
);
free
(
submodule
->
object_name
);
free
(
submodule
->
pp_shortcuts
);
LOAD_STRING
(
submodule
->
object_name
);
LOAD_STRING
(
submodule
->
psz_shortname
);
LOAD_STRING
(
submodule
->
psz_longname
);
LOAD_STRING
(
submodule
->
psz_help
);
...
...
@@ -247,8 +242,6 @@ size_t CacheLoad( vlc_object_t *p_this, const char *dir, module_cache_t **r )
LOAD_IMMEDIATE
(
submodule
->
i_shortcuts
);
if
(
submodule
->
i_shortcuts
>
MODULE_SHORTCUT_MAX
)
goto
error
;
else
if
(
submodule
->
i_shortcuts
==
0
)
submodule
->
pp_shortcuts
=
NULL
;
else
{
submodule
->
pp_shortcuts
=
...
...
@@ -497,7 +490,6 @@ static int CacheSaveBank (FILE *file, const module_cache_t *cache,
uint32_t
i_submodule
;
/* Save additional infos */
SAVE_STRING
(
module
->
object_name
);
SAVE_STRING
(
module
->
psz_shortname
);
SAVE_STRING
(
module
->
psz_longname
);
SAVE_STRING
(
module
->
psz_help
);
...
...
@@ -541,7 +533,6 @@ static int CacheSaveSubmodule( FILE *file, const module_t *p_module )
if
(
CacheSaveSubmodule
(
file
,
p_module
->
next
)
)
goto
error
;
SAVE_STRING
(
p_module
->
object_name
);
SAVE_STRING
(
p_module
->
psz_shortname
);
SAVE_STRING
(
p_module
->
psz_longname
);
SAVE_STRING
(
p_module
->
psz_help
);
...
...
src/modules/entry.c
View file @
224742db
...
...
@@ -39,7 +39,6 @@ static void vlc_module_destruct (gc_object_t *obj)
module_t
*
module
=
vlc_priv
(
obj
,
module_t
);
free
(
module
->
pp_shortcuts
);
free
(
module
->
object_name
);
free
(
module
);
}
...
...
@@ -49,7 +48,6 @@ module_t *vlc_module_create (void)
if
(
module
==
NULL
)
return
NULL
;
module
->
object_name
=
NULL
;
module
->
next
=
NULL
;
module
->
submodule
=
NULL
;
module
->
parent
=
NULL
;
...
...
@@ -82,8 +80,8 @@ module_t *vlc_module_create (void)
static
void
vlc_submodule_destruct
(
gc_object_t
*
obj
)
{
module_t
*
module
=
vlc_priv
(
obj
,
module_t
);
free
(
module
->
pp_shortcuts
);
free
(
module
->
object_name
);
free
(
module
);
}
...
...
@@ -107,7 +105,6 @@ module_t *vlc_submodule_create (module_t *module)
submodule
->
pp_shortcuts
[
0
]
=
module
->
pp_shortcuts
[
0
];
/* object name */
submodule
->
i_shortcuts
=
1
;
submodule
->
object_name
=
strdup
(
module
->
object_name
);
submodule
->
psz_shortname
=
module
->
psz_shortname
;
submodule
->
psz_longname
=
module
->
psz_longname
;
submodule
->
psz_capability
=
module
->
psz_capability
;
...
...
@@ -222,8 +219,7 @@ int vlc_plugin_set (module_t *module, module_config_t *item, int propid, ...)
{
const
char
*
value
=
va_arg
(
ap
,
const
char
*
);
assert
(
module
->
object_name
==
NULL
);
module
->
object_name
=
strdup
(
value
);
assert
(
module
->
i_shortcuts
==
0
);
module
->
pp_shortcuts
=
malloc
(
sizeof
(
char
**
)
);
module
->
pp_shortcuts
[
0
]
=
(
char
*
)
value
;
/* dooh! */
module
->
i_shortcuts
=
1
;
...
...
src/modules/modules.c
View file @
224742db
...
...
@@ -203,9 +203,9 @@ bool module_provides( const module_t *m, const char *cap )
*/
const
char
*
module_get_object
(
const
module_t
*
m
)
{
if
(
unlikely
(
m
->
object_name
==
NULL
))
if
(
unlikely
(
m
->
i_shortcuts
==
0
))
return
"unnamed"
;
return
m
->
object_name
;
return
m
->
pp_shortcuts
[
0
]
;
}
/**
...
...
@@ -680,11 +680,9 @@ module_t *module_find (const char *name)
for
(
size_t
i
=
0
;
(
module
=
list
[
i
])
!=
NULL
;
i
++
)
{
const
char
*
objname
=
module
->
object_name
;
if
(
unlikely
(
objname
==
NULL
))
if
(
unlikely
(
module
->
i_shortcuts
==
0
))
continue
;
if
(
!
strcmp
(
objname
,
name
))
if
(
!
strcmp
(
module
->
pp_shortcuts
[
0
]
,
name
))
{
module_hold
(
module
);
break
;
...
...
src/modules/modules.h
View file @
224742db
...
...
@@ -62,7 +62,6 @@ typedef void * module_handle_t;
*/
struct
module_t
{
char
*
object_name
;
gc_object_t
vlc_gc_data
;
module_t
*
next
;
...
...
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