summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 995f5d3)
raw | patch | inline | side by side (parent: 995f5d3)
author | Max Kellermann <max@duempel.org> | |
Tue, 16 Sep 2008 17:11:39 +0000 (19:11 +0200) | ||
committer | Max Kellermann <max@duempel.org> | |
Tue, 16 Sep 2008 17:11:39 +0000 (19:11 +0200) |
Pass const pointers whenever possible.
src/libmpdclient.c | patch | blob | history | |
src/libmpdclient.h | patch | blob | history |
diff --git a/src/libmpdclient.c b/src/libmpdclient.c
index b0498445e0adafd997922e17f950835297da4905..248d8ea2f974d1e7ffcd8ea1610ca85114879b04 100644 (file)
--- a/src/libmpdclient.c
+++ b/src/libmpdclient.c
free(song);
}
-mpd_Song * mpd_songDup(mpd_Song * song) {
+mpd_Song * mpd_songDup(const mpd_Song * song) {
mpd_Song * ret = mpd_newSong();
if(song->file) ret->file = str_pool_dup(song->file);
diff --git a/src/libmpdclient.h b/src/libmpdclient.h
index fe1991edc28f1f63d03e991b1e5ba0be8001fb8b..1f044aabba362e7ffeeb707480b64a92389a194b 100644 (file)
--- a/src/libmpdclient.h
+++ b/src/libmpdclient.h
/* mpd_songDup
* works like strDup, but for a mpd_Song
*/
-mpd_Song * mpd_songDup(mpd_Song * song);
+mpd_Song * mpd_songDup(const mpd_Song * song);
/* DIRECTORY STUFF */