Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
mpd
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Иван Мажукин
mpd
Commits
a8dbd8f4
Commit
a8dbd8f4
authored
Jan 03, 2009
by
Max Kellermann
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update: don't check for symlinks on WIN32
WIN32 does have some kind of symbolic links (e.g. in NTFS), but the readlink() function is not available. Disable symlink checking for now.
parent
48aace18
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
15 additions
and
0 deletions
+15
-0
update.c
src/update.c
+15
-0
No files found.
src/update.c
View file @
a8dbd8f4
...
...
@@ -68,6 +68,8 @@ static struct song *delete;
static
struct
condition
delete_cond
;
#ifndef WIN32
enum
{
DEFAULT_FOLLOW_INSIDE_SYMLINKS
=
true
,
DEFAULT_FOLLOW_OUTSIDE_SYMLINKS
=
true
,
...
...
@@ -76,6 +78,8 @@ enum {
static
bool
follow_inside_symlinks
;
static
bool
follow_outside_symlinks
;
#endif
unsigned
isUpdatingDB
(
void
)
{
...
...
@@ -427,6 +431,7 @@ static bool skip_path(const char *path)
static
bool
skip_symlink
(
const
struct
directory
*
directory
,
const
char
*
utf8_name
)
{
#ifndef WIN32
char
buffer
[
MPD_PATH_MAX
];
char
*
path_fs
;
const
char
*
p
;
...
...
@@ -476,6 +481,14 @@ skip_symlink(const struct directory *directory, const char *utf8_name)
to a song which is already in the database - skip according
to the follow_inside_symlinks param*/
return
!
follow_inside_symlinks
;
#else
/* no symlink checking on WIN32 */
(
void
)
directory
;
(
void
)
utf8_name
;
return
false
;
#endif
}
static
bool
...
...
@@ -697,6 +710,7 @@ static void reap_update_task(void)
void
update_global_init
(
void
)
{
#ifndef WIN32
follow_inside_symlinks
=
config_get_bool
(
CONF_FOLLOW_INSIDE_SYMLINKS
,
DEFAULT_FOLLOW_INSIDE_SYMLINKS
);
...
...
@@ -704,6 +718,7 @@ void update_global_init(void)
follow_outside_symlinks
=
config_get_bool
(
CONF_FOLLOW_OUTSIDE_SYMLINKS
,
DEFAULT_FOLLOW_OUTSIDE_SYMLINKS
);
#endif
cond_init
(
&
delete_cond
);
...
...
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