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
9a957000
Commit
9a957000
authored
May 06, 2009
by
Rémi Denis-Courmont
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Refactor
parent
579d4ae7
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
10 deletions
+13
-10
src/config/file.c
src/config/file.c
+13
-10
No files found.
src/config/file.c
View file @
9a957000
...
@@ -52,22 +52,25 @@ static inline char *strdupnull (const char *src)
...
@@ -52,22 +52,25 @@ static inline char *strdupnull (const char *src)
/**
/**
* Get the user's configuration file
* Get the user's configuration file
*/
*/
static
char
*
config_GetConfigFile
(
v
oid
)
static
char
*
config_GetConfigFile
(
v
lc_object_t
*
obj
)
{
{
char
*
psz_dir
=
config_GetUserConfDir
();
char
*
psz_file
=
config_GetPsz
(
obj
,
"config"
);
char
*
psz_configfile
;
if
(
psz_file
==
NULL
)
{
char
*
psz_dir
=
config_GetUserConfDir
();
if
(
asprintf
(
&
psz_configfile
,
"%s"
DIR_SEP
CONFIG_FILE
,
psz_dir
)
==
-
1
)
if
(
asprintf
(
&
psz_file
,
"%s"
DIR_SEP
CONFIG_FILE
,
psz_dir
)
==
-
1
)
psz_configfile
=
NULL
;
psz_file
=
NULL
;
free
(
psz_dir
);
free
(
psz_dir
);
return
psz_configfile
;
}
return
psz_file
;
}
}
static
FILE
*
config_OpenConfigFile
(
vlc_object_t
*
p_obj
,
const
char
*
mode
)
static
FILE
*
config_OpenConfigFile
(
vlc_object_t
*
p_obj
,
const
char
*
mode
)
{
{
char
*
psz_filename
=
config_Get
Psz
(
p_obj
,
"config"
);
char
*
psz_filename
=
config_Get
ConfigFile
(
p_obj
);
if
(
!
psz_filename
)
if
(
psz_filename
==
NULL
)
psz_filename
=
config_GetConfigFile
()
;
return
NULL
;
msg_Dbg
(
p_obj
,
"opening config file (%s)"
,
psz_filename
);
msg_Dbg
(
p_obj
,
"opening config file (%s)"
,
psz_filename
);
...
...
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