Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-2-2
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-2-2
Commits
649df079
Commit
649df079
authored
Nov 16, 2004
by
Clément Stenac
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Strip parent path in directory access
parent
15cb035e
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
16 additions
and
1 deletion
+16
-1
modules/access/directory.c
modules/access/directory.c
+16
-1
No files found.
modules/access/directory.c
View file @
649df079
...
...
@@ -399,10 +399,23 @@ static int ReadDir( playlist_t *p_playlist,
}
else
if
(
i_mode
==
MODE_EXPAND
)
{
char
*
psz_newname
;
msg_Dbg
(
p_playlist
,
"Reading subdirectory %s"
,
psz_uri
);
if
(
!
strncmp
(
psz_uri
,
psz_name
,
strlen
(
psz_name
)
)
)
{
char
*
psz_subdir
=
psz_uri
;
/* Skip the parent path + the separator */
psz_subdir
+=
strlen
(
psz_name
)
+
1
;
psz_newname
=
strdup
(
psz_subdir
);
}
else
{
psz_newname
=
strdup
(
psz_uri
);
}
p_node
=
playlist_NodeCreate
(
p_playlist
,
p_parent
->
pp_parents
[
0
]
->
i_view
,
psz_
uri
,
p_parent
);
psz_
newname
,
p_parent
);
playlist_CopyParents
(
p_parent
,
p_node
);
...
...
@@ -413,6 +426,8 @@ static int ReadDir( playlist_t *p_playlist,
{
return
VLC_EGENERIC
;
}
free
(
psz_newname
);
}
}
else
...
...
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