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
12bcba8b
Commit
12bcba8b
authored
Aug 29, 2008
by
Max Kellermann
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
pass constant pointers
And again, convert arguments to const.
parent
d8a8fa63
Hide whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
17 additions
and
16 deletions
+17
-16
audio.c
src/audio.c
+1
-1
audio.h
src/audio.h
+1
-1
audioOutput.c
src/audioOutput.c
+1
-1
audioOutput.h
src/audioOutput.h
+2
-2
ls.c
src/ls.c
+3
-3
ls.h
src/ls.h
+2
-2
tagTracker.c
src/tagTracker.c
+1
-1
tagTracker.h
src/tagTracker.h
+1
-1
tree.c
src/tree.c
+3
-3
tree.h
src/tree.h
+2
-1
No files found.
src/audio.c
View file @
12bcba8b
...
...
@@ -419,7 +419,7 @@ void closeAudioDevice(void)
audioOpened
=
0
;
}
void
sendMetadataToAudioDevice
(
MpdTag
*
tag
)
void
sendMetadataToAudioDevice
(
const
MpdTag
*
tag
)
{
unsigned
int
i
;
...
...
src/audio.h
View file @
12bcba8b
...
...
@@ -55,7 +55,7 @@ int isAudioDeviceOpen(void);
int
isCurrentAudioFormat
(
const
AudioFormat
*
audioFormat
);
void
sendMetadataToAudioDevice
(
MpdTag
*
tag
);
void
sendMetadataToAudioDevice
(
const
MpdTag
*
tag
);
/* these functions are called in the main parent process while the child
process is busy playing to the audio */
...
...
src/audioOutput.c
View file @
12bcba8b
...
...
@@ -244,7 +244,7 @@ void finishAudioOutput(AudioOutput * audioOutput)
free
(
audioOutput
->
convBuffer
);
}
void
sendMetadataToAudioOutput
(
AudioOutput
*
audioOutput
,
MpdTag
*
tag
)
void
sendMetadataToAudioOutput
(
AudioOutput
*
audioOutput
,
const
MpdTag
*
tag
)
{
if
(
!
audioOutput
->
sendMetdataFunc
)
return
;
...
...
src/audioOutput.h
View file @
12bcba8b
...
...
@@ -50,7 +50,7 @@ typedef void (*AudioOutputDropBufferedAudioFunc) (AudioOutput * audioOutput);
typedef
void
(
*
AudioOutputCloseDeviceFunc
)
(
AudioOutput
*
audioOutput
);
typedef
void
(
*
AudioOutputSendMetadataFunc
)
(
AudioOutput
*
audioOutput
,
MpdTag
*
tag
);
const
MpdTag
*
tag
);
struct
_AudioOutput
{
int
open
;
...
...
@@ -104,7 +104,7 @@ void dropBufferedAudioOutput(AudioOutput * audioOutput);
void
closeAudioOutput
(
AudioOutput
*
audioOutput
);
void
finishAudioOutput
(
AudioOutput
*
audioOutput
);
int
keepAudioOutputAlive
(
AudioOutput
*
audioOutput
,
int
ms
);
void
sendMetadataToAudioOutput
(
AudioOutput
*
audioOutput
,
MpdTag
*
tag
);
void
sendMetadataToAudioOutput
(
AudioOutput
*
audioOutput
,
const
MpdTag
*
tag
);
void
printAllOutputPluginTypes
(
FILE
*
fp
);
...
...
src/ls.c
View file @
12bcba8b
...
...
@@ -42,10 +42,10 @@ int printRemoteUrlHandlers(int fd)
return
0
;
}
int
isValidRemoteUtf8Url
(
char
*
utf8url
)
int
isValidRemoteUtf8Url
(
c
onst
c
har
*
utf8url
)
{
int
ret
=
0
;
char
*
temp
;
c
onst
c
har
*
temp
;
switch
(
isRemoteUrl
(
utf8url
))
{
case
1
:
...
...
@@ -82,7 +82,7 @@ int isValidRemoteUtf8Url(char *utf8url)
return
ret
;
}
int
isRemoteUrl
(
char
*
url
)
int
isRemoteUrl
(
c
onst
c
har
*
url
)
{
int
count
=
0
;
const
char
**
urlPrefixes
=
remoteUrlPrefixes
;
...
...
src/ls.h
View file @
12bcba8b
...
...
@@ -25,9 +25,9 @@ int lsPlaylists(int fd, const char *utf8path);
const
char
*
getSuffix
(
const
char
*
utf8file
);
int
isValidRemoteUtf8Url
(
char
*
utf8url
);
int
isValidRemoteUtf8Url
(
c
onst
c
har
*
utf8url
);
int
isRemoteUrl
(
char
*
url
);
int
isRemoteUrl
(
c
onst
c
har
*
url
);
int
myStat
(
const
char
*
utf8file
,
struct
stat
*
st
);
...
...
src/tagTracker.c
View file @
12bcba8b
...
...
@@ -106,7 +106,7 @@ void resetVisitedFlagsInTagTracker(int type)
}
}
void
visitInTagTracker
(
int
type
,
char
*
str
)
void
visitInTagTracker
(
int
type
,
c
onst
c
har
*
str
)
{
TreeIterator
iter
;
...
...
src/tagTracker.h
View file @
12bcba8b
...
...
@@ -29,7 +29,7 @@ void printMemorySavedByTagTracker(void);
void
resetVisitedFlagsInTagTracker
(
int
type
);
void
visitInTagTracker
(
int
type
,
char
*
str
);
void
visitInTagTracker
(
int
type
,
c
onst
c
har
*
str
);
void
printVisitedInTagTracker
(
int
fd
,
int
type
);
...
...
src/tree.c
View file @
12bcba8b
...
...
@@ -71,7 +71,7 @@ _ClearKeyData(TreeKeyData * keyData)
static
int
_FindPosition
(
Tree
*
tree
,
TreeNode
*
node
,
void
*
key
,
int
*
pos
)
_FindPosition
(
Tree
*
tree
,
TreeNode
*
node
,
const
void
*
key
,
int
*
pos
)
{
#ifdef USE_BINARY_SEARCH
int
low
=
0
;
...
...
@@ -113,7 +113,7 @@ _FindPosition(Tree * tree, TreeNode * node, void * key, int * pos)
static
int
_Find
(
TreeIterator
*
iter
,
void
*
key
)
_Find
(
TreeIterator
*
iter
,
const
void
*
key
)
{
while
(
1
)
{
...
...
@@ -680,7 +680,7 @@ RemoveFromTreeByIterator(Tree * tree, TreeIterator * iter)
}
int
FindInTree
(
Tree
*
tree
,
void
*
key
,
TreeIterator
*
iter
)
FindInTree
(
Tree
*
tree
,
const
void
*
key
,
TreeIterator
*
iter
)
{
TreeIterator
i
;
...
...
src/tree.h
View file @
12bcba8b
...
...
@@ -57,6 +57,7 @@ int InsertInTree(Tree * tree, void * key, void * data);
int
RemoveFromTreeByKey
(
Tree
*
tree
,
void
*
key
);
void
RemoveFromTreeByIterator
(
Tree
*
tree
,
TreeIterator
*
iter
);
int
FindInTree
(
Tree
*
tree
,
void
*
key
,
TreeIterator
*
iter
/* can be NULL */
);
int
FindInTree
(
Tree
*
tree
,
const
void
*
key
,
TreeIterator
*
iter
/* can be NULL */
);
#endif
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