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
05e2ddbc
Commit
05e2ddbc
authored
Nov 27, 2015
by
Hugo Beauzée-Luyssen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
audioscrobbler: Remove useless allocations
parent
85bbd21f
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
14 deletions
+7
-14
modules/misc/audioscrobbler.c
modules/misc/audioscrobbler.c
+7
-14
No files found.
modules/misc/audioscrobbler.c
View file @
05e2ddbc
...
@@ -196,18 +196,11 @@ static void ReadMetaData(intf_thread_t *p_this, input_thread_t *p_input)
...
@@ -196,18 +196,11 @@ static void ReadMetaData(intf_thread_t *p_this, input_thread_t *p_input)
p_sys
->
b_submit_nowp
=
true
;
p_sys
->
b_submit_nowp
=
true
;
ALLOC_ITEM_META
(
p_sys
->
p_current_song
.
psz_b
,
Album
);
ALLOC_ITEM_META
(
p_sys
->
p_current_song
.
psz_b
,
Album
);
if
(
!
p_sys
->
p_current_song
.
psz_b
)
p_sys
->
p_current_song
.
psz_b
=
calloc
(
1
,
1
);
ALLOC_ITEM_META
(
p_sys
->
p_current_song
.
psz_m
,
TrackID
);
ALLOC_ITEM_META
(
p_sys
->
p_current_song
.
psz_m
,
TrackID
);
if
(
!
p_sys
->
p_current_song
.
psz_m
)
ALLOC_ITEM_META
(
p_sys
->
p_current_song
.
psz_n
,
TrackNum
);
p_sys
->
p_current_song
.
psz_m
=
calloc
(
1
,
1
);
p_sys
->
p_current_song
.
i_l
=
input_item_GetDuration
(
p_item
)
/
1000000
;
p_sys
->
p_current_song
.
i_l
=
input_item_GetDuration
(
p_item
)
/
1000000
;
ALLOC_ITEM_META
(
p_sys
->
p_current_song
.
psz_n
,
TrackNum
);
if
(
!
p_sys
->
p_current_song
.
psz_n
)
p_sys
->
p_current_song
.
psz_n
=
calloc
(
1
,
1
);
#undef ALLOC_ITEM_META
#undef ALLOC_ITEM_META
msg_Dbg
(
p_this
,
"Meta data registered"
);
msg_Dbg
(
p_this
,
"Meta data registered"
);
...
@@ -770,10 +763,10 @@ static void *Run(void *data)
...
@@ -770,10 +763,10 @@ static void *Run(void *data)
"&m=%s"
,
"&m=%s"
,
p_sys
->
p_current_song
.
psz_a
,
p_sys
->
p_current_song
.
psz_a
,
p_sys
->
p_current_song
.
psz_t
,
p_sys
->
p_current_song
.
psz_t
,
p_sys
->
p_current_song
.
psz_b
,
p_sys
->
p_current_song
.
psz_b
?
p_sys
->
p_current_song
.
psz_b
:
""
,
p_sys
->
p_current_song
.
i_l
,
p_sys
->
p_current_song
.
i_l
,
p_sys
->
p_current_song
.
psz_n
,
p_sys
->
p_current_song
.
psz_n
?
p_sys
->
p_current_song
.
psz_n
:
""
,
p_sys
->
p_current_song
.
psz_m
p_sys
->
p_current_song
.
psz_m
?
p_sys
->
p_current_song
.
psz_m
:
""
)
==
-
1
)
)
==
-
1
)
{
/* Out of memory */
{
/* Out of memory */
vlc_mutex_unlock
(
&
p_sys
->
lock
);
vlc_mutex_unlock
(
&
p_sys
->
lock
);
...
@@ -804,9 +797,9 @@ static void *Run(void *data)
...
@@ -804,9 +797,9 @@ static void *Run(void *data)
i_song
,
i_song
,
i_song
,
i_song
,
i_song
,
p_song
->
i_l
,
i_song
,
p_song
->
i_l
,
i_song
,
p_song
->
psz_b
,
i_song
,
p_song
->
psz_b
?
p_song
->
psz_b
:
""
,
i_song
,
p_song
->
psz_n
,
i_song
,
p_song
->
psz_n
?
p_song
->
psz_n
:
""
,
i_song
,
p_song
->
psz_m
i_song
,
p_song
->
psz_m
?
p_song
->
psz_m
:
""
)
==
-
1
)
)
==
-
1
)
{
/* Out of memory */
{
/* Out of memory */
vlc_mutex_unlock
(
&
p_sys
->
lock
);
vlc_mutex_unlock
(
&
p_sys
->
lock
);
...
...
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