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
7a023eb0
Commit
7a023eb0
authored
Oct 08, 2008
by
Max Kellermann
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
database: removed printDirectoryInfo()
The same can be achieved with directory_print(db_get_directory()).
parent
8a50e8a2
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
5 additions
and
14 deletions
+5
-14
command.c
src/command.c
+5
-1
database.c
src/database.c
+0
-10
database.h
src/database.h
+0
-3
No files found.
src/command.c
View file @
7a023eb0
...
...
@@ -574,16 +574,20 @@ static int handleLsInfo(struct client *client,
int
argc
,
char
*
argv
[])
{
const
char
*
path
=
""
;
const
struct
directory
*
directory
;
if
(
argc
==
2
)
path
=
argv
[
1
];
if
(
printDirectoryInfo
(
client
,
path
)
<
0
)
{
directory
=
getDirectory
(
path
);
if
(
directory
==
NULL
)
{
command_error
(
client
,
ACK_ERROR_NO_EXIST
,
"directory not found"
);
return
-
1
;
}
directory_print
(
client
,
directory
);
if
(
isRootDirectory
(
path
))
return
lsPlaylists
(
client
,
path
);
...
...
src/database.c
View file @
7a023eb0
...
...
@@ -115,16 +115,6 @@ traverseAllIn(const char *name,
data
);
}
int
printDirectoryInfo
(
struct
client
*
client
,
const
char
*
name
)
{
struct
directory
*
directory
;
if
((
directory
=
getDirectory
(
name
))
==
NULL
)
return
-
1
;
return
directory_print
(
client
,
directory
);
}
static
char
*
getDbFile
(
void
)
{
ConfigParam
*
param
=
parseConfigFilePath
(
CONF_DB_FILE
,
1
);
...
...
src/database.h
View file @
7a023eb0
...
...
@@ -23,7 +23,6 @@
#include <sys/time.h>
struct
directory
;
struct
client
;
void
directory_init
(
void
);
...
...
@@ -42,8 +41,6 @@ int traverseAllIn(const char *name,
int
(
*
forEachSong
)
(
struct
song
*
,
void
*
),
int
(
*
forEachDir
)
(
struct
directory
*
,
void
*
),
void
*
data
);
int
printDirectoryInfo
(
struct
client
*
client
,
const
char
*
name
);
int
checkDirectoryDB
(
void
);
int
writeDirectoryDB
(
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