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
832f2aa8
Commit
832f2aa8
authored
Apr 25, 2009
by
Rémi Duraffort
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
playlist_sort: sort using the title and fallback to the name when the title is empty.
(this fix the sort which was buggy).
parent
19efca33
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
2 deletions
+4
-2
src/playlist/sort.c
src/playlist/sort.c
+4
-2
No files found.
src/playlist/sort.c
View file @
832f2aa8
...
...
@@ -119,8 +119,10 @@ static int playlist_cmp(const void *first, const void *second)
{
#define META_STRCASECMP_NAME( ) { \
char *psz_i = input_item_GetName( (*(playlist_item_t **)first)->p_input ); \
char *psz_ismall = input_item_GetName( (*(playlist_item_t **)second)->p_input ); \
char *psz_i = input_item_GetTitle( (*(playlist_item_t **)first)->p_input ); \
char *psz_ismall = input_item_GetTitle( (*(playlist_item_t **)second)->p_input ); \
if(EMPTY_STR(psz_i)) {free(psz_i); psz_i = input_item_GetName( (*(playlist_item_t **)first)->p_input ); }\
if(EMPTY_STR(psz_ismall)) {free(psz_ismall); psz_ismall = input_item_GetName( (*(playlist_item_t **)second)->p_input ); }\
if( psz_i != NULL && psz_ismall != NULL ) i_test = strcasecmp( psz_i, psz_ismall ); \
else if ( psz_i == NULL && psz_ismall != NULL ) i_test = 1; \
else if ( psz_ismall == NULL && psz_i != NULL ) i_test = -1; \
...
...
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