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
f31c371f
Commit
f31c371f
authored
Mar 11, 2009
by
Jochen Keil
Committed by
Max Kellermann
Mar 14, 2009
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Removed superfluous if statement in update.c:453
Check for NULL not necessary here
parent
0aee49bd
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
22 additions
and
28 deletions
+22
-28
update.c
src/update.c
+22
-28
No files found.
src/update.c
View file @
f31c371f
...
...
@@ -450,42 +450,36 @@ update_container_file( struct directory* directory,
return
true
;
}
// contdir doesn't yet exist
if
(
contdir
==
NULL
)
{
contdir
=
make_subdir
(
directory
,
name
);
contdir
->
mtime
=
st
->
st_mtime
;
contdir
->
device
=
DEVICE_CONTAINER
;
contdir
=
make_subdir
(
directory
,
name
);
contdir
->
mtime
=
st
->
st_mtime
;
contdir
->
device
=
DEVICE_CONTAINER
;
while
((
vtrack
=
plugin
->
container_scan
(
pathname
,
++
tnum
))
!=
NULL
)
{
struct
song
*
song
=
song_file_new
(
vtrack
,
contdir
);
if
(
song
==
NULL
)
return
true
;
while
((
vtrack
=
plugin
->
container_scan
(
pathname
,
++
tnum
))
!=
NULL
)
{
struct
song
*
song
=
song_file_new
(
vtrack
,
contdir
);
if
(
song
==
NULL
)
return
true
;
// shouldn't be necessary but it's there..
song
->
mtime
=
st
->
st_mtime
;
// shouldn't be necessary but it's there..
song
->
mtime
=
st
->
st_mtime
;
song
->
tag
=
plugin
->
tag_dup
(
map_directory_child_fs
(
contdir
,
vtrack
));
song
->
tag
=
plugin
->
tag_dup
(
map_directory_child_fs
(
contdir
,
vtrack
));
songvec_add
(
&
contdir
->
songs
,
song
);
song
=
NULL
;
songvec_add
(
&
contdir
->
songs
,
song
);
song
=
NULL
;
modified
=
true
;
modified
=
true
;
g_free
(
vtrack
);
}
g_free
(
vtrack
);
}
if
(
tnum
==
1
)
{
delete_directory
(
contdir
);
return
false
;
}
else
return
true
;
if
(
tnum
==
1
)
{
delete_directory
(
contdir
);
return
false
;
}
// something went wrong, so return true to return update_regular_fil
e
return
true
;
els
e
return
true
;
}
static
void
...
...
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