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
5281440c
Commit
5281440c
authored
Aug 26, 2009
by
Rémi Denis-Courmont
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove config_GetCacheDir
parent
a8c111dd
Changes
9
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
14 additions
and
39 deletions
+14
-39
include/vlc_configuration.h
include/vlc_configuration.h
+2
-2
modules/codec/libass.c
modules/codec/libass.c
+1
-1
modules/misc/lua/libs/misc.c
modules/misc/lua/libs/misc.c
+1
-1
src/config/dirs_macos.c
src/config/dirs_macos.c
+2
-16
src/config/dirs_win.c
src/config/dirs_win.c
+2
-6
src/config/dirs_xdg.c
src/config/dirs_xdg.c
+3
-9
src/libvlccore.sym
src/libvlccore.sym
+0
-1
src/modules/cache.c
src/modules/cache.c
+2
-2
src/playlist/art.c
src/playlist/art.c
+1
-1
No files found.
include/vlc_configuration.h
View file @
5281440c
...
...
@@ -222,8 +222,9 @@ typedef enum vlc_userdir
VLC_HOME_DIR
,
/* User's home */
VLC_CONFIG_DIR
,
/* VLC-specific configuration directory */
VLC_DATA_DIR
,
/* VLC-specific data directory */
VLC_CACHE_DIR
,
/* VLC-specific user cached data directory */
/* Generic directories (same as XDG) */
VLC_DESKTOP_DIR
,
VLC_DESKTOP_DIR
=
0x80
,
VLC_DOWNLOAD_DIR
,
VLC_TEMPLATES_DIR
,
VLC_PUBLICSHARE_DIR
,
...
...
@@ -234,7 +235,6 @@ typedef enum vlc_userdir
}
vlc_userdir_t
;
VLC_EXPORT
(
char
*
,
config_GetUserDir
,
(
vlc_userdir_t
)
LIBVLC_USED
);
VLC_EXPORT
(
char
*
,
config_GetCacheDir
,
(
void
)
LIBVLC_USED
);
VLC_EXPORT
(
void
,
__config_AddIntf
,
(
vlc_object_t
*
,
const
char
*
)
);
VLC_EXPORT
(
void
,
__config_RemoveIntf
,
(
vlc_object_t
*
,
const
char
*
)
);
...
...
modules/codec/libass.c
View file @
5281440c
...
...
@@ -724,7 +724,7 @@ static ass_handle_t *AssHandleHold( decoder_t *p_dec )
}
#endif
if
(
!
psz_font_dir
)
psz_font_dir
=
config_Get
CacheDir
(
);
psz_font_dir
=
config_Get
UserDir
(
VLC_CACHE_DIR
);
if
(
!
psz_font_dir
)
goto
error
;
...
...
modules/misc/lua/libs/misc.c
View file @
5281440c
...
...
@@ -144,7 +144,7 @@ static int vlclua_configdir( lua_State *L )
static
int
vlclua_cachedir
(
lua_State
*
L
)
{
char
*
dir
=
config_Get
CacheDir
(
);
char
*
dir
=
config_Get
UserDir
(
VLC_CACHE_DIR
);
lua_pushstring
(
L
,
dir
);
free
(
dir
);
return
1
;
...
...
src/config/dirs_macos.c
View file @
5281440c
...
...
@@ -133,21 +133,6 @@ static char *config_GetAppDir (void)
return
psz_dir
;
}
/**
* Get the user's VLC cache directory
* (used for stuff like the modules cache, the album art cache, ...)
*/
char
*
config_GetCacheDir
(
void
)
{
char
*
psz_dir
;
const
char
*
psz_parent
=
GetDir
(
false
);
if
(
asprintf
(
&
psz_dir
,
"%s/Library/Preferences/VLC"
,
psz_parent
)
==
-
1
)
psz_dir
=
NULL
;
return
psz_dir
;
}
char
*
config_GetUserDir
(
vlc_userdir_t
type
)
{
switch
(
type
)
...
...
@@ -155,9 +140,10 @@ char *config_GetUserDir (vlc_userdir_t type)
case
VLC_HOME_DIR
:
return
config_GetHomeDir
();
case
VLC_CONFIG_DIR
:
return
config_GetAppDir
();
case
VLC_DATA_DIR
:
case
VLC_CACHE_DIR
:
return
config_GetAppDir
();
case
VLC_DESKTOP_DIR
:
case
VLC_DOWNLOAD_DIR
:
case
VLC_TEMPLATES_DIR
:
...
...
src/config/dirs_win.c
View file @
5281440c
...
...
@@ -109,11 +109,6 @@ static char *config_GetAppDir (void)
return
psz_dir
;
}
char
*
config_GetCacheDir
(
void
)
{
return
config_GetAppDir
();
}
char
*
config_GetUserDir
(
vlc_userdir_t
type
)
{
switch
(
type
)
...
...
@@ -121,9 +116,10 @@ char *config_GetUserDir (vlc_userdir_t type)
case
VLC_HOME_DIR
:
return
config_GetShellDir
(
CSIDL_PERSONAL
);
case
VLC_CONFIG_DIR
:
return
config_GetAppDir
();
case
VLC_DATA_DIR
:
case
VLC_CACHE_DIR
:
return
config_GetAppDir
();
case
VLC_DESKTOP_DIR
:
case
VLC_DOWNLOAD_DIR
:
case
VLC_TEMPLATES_DIR
:
...
...
src/config/dirs_xdg.c
View file @
5281440c
...
...
@@ -199,15 +199,6 @@ done:
}
/**
* Get the user's VLC cache directory
* (used for stuff like the modules cache, the album art cache, ...)
*/
char
*
config_GetCacheDir
(
void
)
{
return
config_GetAppDir
(
"CACHE"
,
".cache"
);
}
char
*
config_GetUserDir
(
vlc_userdir_t
type
)
{
switch
(
type
)
...
...
@@ -218,6 +209,9 @@ char *config_GetUserDir (vlc_userdir_t type)
return
config_GetAppDir
(
"CONFIG"
,
".config"
);
case
VLC_DATA_DIR
:
return
config_GetAppDir
(
"DATA"
,
".local/share"
);
case
VLC_CACHE_DIR
:
return
config_GetAppDir
(
"CACHE"
,
".cache"
);
case
VLC_DESKTOP_DIR
:
return
config_GetTypeDir
(
"DESKTOP"
);
case
VLC_DOWNLOAD_DIR
:
...
...
src/libvlccore.sym
View file @
5281440c
...
...
@@ -50,7 +50,6 @@ config_ChainDuplicate
__config_ChainParse
__config_ExistIntf
config_FindConfig
config_GetCacheDir
config_GetConfDir
config_GetDataDir
__config_GetFloat
...
...
src/modules/cache.c
View file @
5281440c
...
...
@@ -104,7 +104,7 @@ static int CacheSaveConfig ( module_t *, FILE * );
*****************************************************************************/
void
CacheLoad
(
vlc_object_t
*
p_this
,
module_bank_t
*
p_bank
,
bool
b_delete
)
{
char
*
psz_filename
,
*
psz_cachedir
=
config_Get
CacheDir
(
);
char
*
psz_filename
,
*
psz_cachedir
=
config_Get
UserDir
(
VLC_CACHE_DIR
);
FILE
*
file
;
int
i
,
j
,
i_size
,
i_read
;
char
p_cachestring
[
sizeof
(
"cache "
COPYRIGHT_MESSAGE
)];
...
...
@@ -475,7 +475,7 @@ void CacheSave( vlc_object_t *p_this, module_bank_t *p_bank )
"# For information about cache directory tags, see:
\r\n
"
"# http://www.brynosaurus.com/cachedir/
\r\n
"
;
char
*
psz_cachedir
=
config_Get
CacheDir
(
);
char
*
psz_cachedir
=
config_Get
UserDir
(
VLC_CACHE_DIR
);
FILE
*
file
;
int
i
,
j
,
i_cache
;
module_cache_t
**
pp_cache
;
...
...
src/playlist/art.c
View file @
5281440c
...
...
@@ -67,7 +67,7 @@ static char* ArtCacheGetDirPath( const char *psz_title, const char *psz_artist,
const
char
*
psz_album
)
{
char
*
psz_dir
;
char
*
psz_cachedir
=
config_Get
CacheDir
(
);
char
*
psz_cachedir
=
config_Get
UserDir
(
VLC_CACHE_DIR
);
if
(
!
EMPTY_STR
(
psz_artist
)
&&
!
EMPTY_STR
(
psz_album
)
)
{
...
...
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