filter: Make ->open() optional.
[paraslash.git] / afs.c
diff --git a/afs.c b/afs.c
index 0b24a3b8cdb7c53f70b09bba317f9afe523d9320..016329841fe87255cdc68c1191e8661124c1c326 100644 (file)
--- a/afs.c
+++ b/afs.c
@@ -497,7 +497,7 @@ no_admissible_files:
 }
 
 /* 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;
@@ -590,7 +590,7 @@ static void flush_and_free_pb(struct para_buffer *pb)
 
 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();
@@ -649,7 +649,7 @@ static int setup_command_socket_or_die(void)
        ret = create_local_socket(socket_name, 0);
        if (ret < 0) {
                ret = create_local_socket(socket_name,
-                       S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP | S_IWOTH);
+                       S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP | S_IROTH | S_IROTH);
                if (ret < 0) {
                        PARA_EMERG_LOG("%s: %s\n", para_strerror(-ret),
                                socket_name);