}
/* Never fails if arg == NULL */
-static int activate_mood_or_playlist(char *arg, int *num_admissible)
+static int activate_mood_or_playlist(const char *arg, int *num_admissible)
{
enum play_mode mode;
int ret;
static int com_select_callback(struct afs_callback_arg *aca)
{
- char *arg = aca->query.data;
+ const char *arg = aca->query.data;
int num_admissible, ret;
ret = clear_score_table();
int aft_check_callback(struct afs_callback_arg *aca);
/* playlist */
-int playlist_open(char *name);
+int playlist_open(const char *name);
void playlist_close(void);
int playlist_check_callback(struct afs_callback_arg *aca);
* \sa struct admissible_file_info, struct admissible_array, struct
* afs_info::last_played, mood_close().
*/
-int change_current_mood(char *mood_name)
+int change_current_mood(const char *mood_name)
{
int i, ret;
struct admissible_array aa = {
struct mood *m;
struct osl_row *row;
struct osl_object obj = {
- .data = mood_name,
+ .data = (char *)mood_name,
.size = strlen(mood_name) + 1
};
ret = osl(osl_get_row(moods_table, BLOBCOL_NAME, &obj, &row));
/** \file mood.h Public functions of mood.c. */
-int change_current_mood(char *mood_name);
+int change_current_mood(const char *mood_name);
void close_current_mood(void);
int mood_check_callback(struct afs_callback_arg *aca);
*
* \return Standard.
*/
-int playlist_open(char *name)
+int playlist_open(const char *name)
{
struct osl_object obj;
int ret;
struct osl_row *row;
- obj.data = name;
+ obj.data = (char *)name;
obj.size = strlen(obj.data);
ret = osl(osl_get_row(playlists_table, BLOBCOL_NAME, &obj, &row));
if (ret < 0) {