Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-1.1
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-1.1
Commits
83d76733
Commit
83d76733
authored
Mar 10, 2005
by
Clément Stenac
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix locking
parent
96611479
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
26 additions
and
30 deletions
+26
-30
modules/access/cdda/info.c
modules/access/cdda/info.c
+26
-30
No files found.
modules/access/cdda/info.c
View file @
83d76733
...
...
@@ -556,16 +556,16 @@ CDDAFormatStr( const access_t *p_access, cdda_data_t *p_cdda,
break
;
#ifdef HAVE_LIBCDDB
case
'a'
:
if
(
p_cdda
->
p_cdtext
[
0
]
&&
p_cdda
->
p_cdtext
[
0
]
->
field
[
CDTEXT_PERFORMER
])
psz
=
p_cdda
->
p_cdtext
[
0
]
->
field
[
CDTEXT_PERFORMER
];
if
(
want_cddb_info
(
p_cdda
,
psz
))
psz
=
p_cdda
->
cddb
.
disc
->
artist
;
if
(
p_cdda
->
p_cdtext
[
0
]
&&
p_cdda
->
p_cdtext
[
0
]
->
field
[
CDTEXT_PERFORMER
])
psz
=
p_cdda
->
p_cdtext
[
0
]
->
field
[
CDTEXT_PERFORMER
];
if
(
want_cddb_info
(
p_cdda
,
psz
))
psz
=
p_cdda
->
cddb
.
disc
->
artist
;
goto
format_str
;
case
'A'
:
if
(
p_cdda
->
p_cdtext
[
0
]
&&
p_cdda
->
p_cdtext
[
0
]
->
field
[
CDTEXT_TITLE
])
psz
=
p_cdda
->
p_cdtext
[
0
]
->
field
[
CDTEXT_TITLE
];
if
(
p_cdda
->
p_cdtext
[
0
]
&&
p_cdda
->
p_cdtext
[
0
]
->
field
[
CDTEXT_TITLE
])
psz
=
p_cdda
->
p_cdtext
[
0
]
->
field
[
CDTEXT_TITLE
];
if
(
want_cddb_info
(
p_cdda
,
psz
))
psz
=
p_cdda
->
cddb
.
disc
->
title
;
goto
format_str
;
...
...
@@ -576,20 +576,20 @@ CDDAFormatStr( const access_t *p_access, cdda_data_t *p_cdda,
CDDB_CATEGORY
[
p_cdda
->
cddb
.
disc
->
category
]);
break
;
case
'G'
:
if
(
p_cdda
->
p_cdtext
[
0
]
&&
p_cdda
->
p_cdtext
[
0
]
->
field
[
CDTEXT_GENRE
])
psz
=
p_cdda
->
p_cdtext
[
0
]
->
field
[
CDTEXT_GENRE
];
if
(
want_cddb_info
(
p_cdda
,
psz
))
psz
=
p_cdda
->
cddb
.
disc
->
genre
;
goto
format_str
;
if
(
p_cdda
->
p_cdtext
[
0
]
&&
p_cdda
->
p_cdtext
[
0
]
->
field
[
CDTEXT_GENRE
])
psz
=
p_cdda
->
p_cdtext
[
0
]
->
field
[
CDTEXT_GENRE
];
if
(
want_cddb_info
(
p_cdda
,
psz
))
psz
=
p_cdda
->
cddb
.
disc
->
genre
;
goto
format_str
;
case
'I'
:
if
(
p_cdda
->
p_cdtext
[
0
]
&&
p_cdda
->
p_cdtext
[
0
]
->
field
[
CDTEXT_DISCID
])
psz
=
p_cdda
->
p_cdtext
[
0
]
->
field
[
CDTEXT_DISCID
];
if
(
want_cddb_info
(
p_cdda
,
psz
))
{
if
(
p_cdda
->
p_cdtext
[
0
]
&&
p_cdda
->
p_cdtext
[
0
]
->
field
[
CDTEXT_DISCID
])
psz
=
p_cdda
->
p_cdtext
[
0
]
->
field
[
CDTEXT_DISCID
];
if
(
want_cddb_info
(
p_cdda
,
psz
))
{
add_format_num_info
(
p_cdda
->
cddb
.
disc
->
discid
,
"%x"
);
}
else
if
(
psz
)
add_format_str_info
(
psz
);
}
else
if
(
psz
)
add_format_str_info
(
psz
);
break
;
case
'Y'
:
if
(
!
p_cdda
->
b_cddb_enabled
)
goto
not_special
;
...
...
@@ -597,18 +597,18 @@ CDDAFormatStr( const access_t *p_access, cdda_data_t *p_cdda,
add_format_num_info
(
p_cdda
->
cddb
.
disc
->
year
,
"%5d"
);
break
;
case
't'
:
if
(
CDIO_INVALID_TRACK
==
i_track
)
break
;
if
(
CDIO_INVALID_TRACK
==
i_track
)
break
;
if
(
p_cdda
&&
p_cdda
->
b_cddb_enabled
&&
p_cdda
->
cddb
.
disc
)
{
cddb_track_t
*
t
=
cddb_disc_get_track
(
p_cdda
->
cddb
.
disc
,
i_track
-
1
);
if
(
t
!=
NULL
&&
t
->
title
!=
NULL
)
{
add_format_str_info
(
t
->
title
);
}
else
{
}
else
{
add_format_str_info
(
psz_mrl
);
}
}
}
else
{
if
(
p_cdda
->
p_cdtext
[
i_track
]
if
(
p_cdda
->
p_cdtext
[
i_track
]
&&
p_cdda
->
p_cdtext
[
i_track
]
->
field
[
CDTEXT_TITLE
])
{
add_format_str_info
(
p_cdda
->
p_cdtext
[
i_track
]
->
field
[
CDTEXT_TITLE
]);
...
...
@@ -847,8 +847,6 @@ int CDDAAddMetaToItem( access_t *p_access, cdda_data_t *p_cdda,
playlist_item_t
*
p_item
,
int
i_track
,
vlc_bool_t
b_single
)
{
vlc_mutex_lock
(
&
p_item
->
input
.
lock
);
add_playlist_track_info_str
(
"Source"
,
p_cdda
->
psz_source
);
vlc_input_item_AddInfo
(
&
p_item
->
input
,
_
(
"Track"
),
_
(
"Track Number"
),
"%d"
,
i_track
);
...
...
@@ -883,18 +881,16 @@ int CDDAAddMetaToItem( access_t *p_access, cdda_data_t *p_cdda,
if
(
t
->
artist
)
add_playlist_track_info_str
(
"Artist (CDDB)"
,
t
->
artist
);
if
(
t
->
title
)
if
(
t
->
title
)
add_playlist_track_info_str
(
"Title (CDDB)"
,
t
->
title
);
if
(
t
->
ext_data
)
if
(
t
->
ext_data
)
add_playlist_track_info_str
(
"Extended information (CDDB)"
,
t
->
ext_data
);
}
}
#endif
/*HAVE_LIBCDDB*/
vlc_mutex_unlock
(
&
p_item
->
input
.
lock
);
return
VLC_SUCCESS
;
}
...
...
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