From b7d2d4cfe8b88174a7b1f41840ddc0b23dbd6a75 Mon Sep 17 00:00:00 2001
From: Max Kellermann <max@duempel.org>
Date: Tue, 13 Sep 2011 21:36:51 +0200
Subject: database: don't allow uri==NULL

Add nonnull attributes and fix all callers.
---
 src/db_print.h | 8 ++++++++
 1 file changed, 8 insertions(+)

(limited to 'src/db_print.h')

diff --git a/src/db_print.h b/src/db_print.h
index 7d6309517..76e43c3a0 100644
--- a/src/db_print.h
+++ b/src/db_print.h
@@ -20,6 +20,8 @@
 #ifndef MPD_DB_PRINT_H
 #define MPD_DB_PRINT_H
 
+#include "gcc.h"
+
 #include <glib.h>
 #include <stdbool.h>
 
@@ -27,28 +29,34 @@ struct client;
 struct locate_item_list;
 struct db_visitor;
 
+gcc_nonnull(1,2)
 bool
 printAllIn(struct client *client, const char *uri_utf8, GError **error_r);
 
+gcc_nonnull(1,2)
 bool
 printInfoForAllIn(struct client *client, const char *uri_utf8,
 		  GError **error_r);
 
+gcc_nonnull(1,2,3)
 bool
 searchForSongsIn(struct client *client, const char *name,
 		 const struct locate_item_list *criteria,
 		 GError **error_r);
 
+gcc_nonnull(1,2,3)
 bool
 findSongsIn(struct client *client, const char *name,
 	    const struct locate_item_list *criteria,
 	    GError **error_r);
 
+gcc_nonnull(1,2,3)
 bool
 searchStatsForSongsIn(struct client *client, const char *name,
 		      const struct locate_item_list *criteria,
 		      GError **error_r);
 
+gcc_nonnull(1,3)
 bool
 listAllUniqueTags(struct client *client, int type,
 		  const struct locate_item_list *criteria,
-- 
cgit v1.2.3