Code

screen_search: check for SEARCH_URI in search_simple_query()
authorMax Kellermann <max@duempel.org>
Sat, 3 Oct 2009 18:13:13 +0000 (20:13 +0200)
committerMax Kellermann <max@duempel.org>
Sat, 3 Oct 2009 18:13:13 +0000 (20:13 +0200)
Call mpd_search_add_uri_constraint() in this case.

src/screen_search.c

index e41e3b09c00542f2bc776bb6674bd50b75d5840b..2dd911d09b3a8cc3c9cccb5518c62176889845a8 100644 (file)
@@ -186,6 +186,13 @@ search_simple_query(struct mpd_connection *connection, bool exact_match,
 
                if (list != NULL)
                        filelist_sort_all(list, compare_filelistentry_format);
+       } else if (table == SEARCH_URI) {
+               mpd_search_db_songs(connection, exact_match);
+               mpd_search_add_uri_constraint(connection, MPD_OPERATOR_DEFAULT,
+                                             filter_utf8);
+               mpd_search_commit(connection);
+
+               list = filelist_new_recv(connection);
        } else {
                mpd_search_db_songs(connection, exact_match);
                mpd_search_add_tag_constraint(connection, MPD_OPERATOR_DEFAULT,