[rygel] server: Prevent critical on upload
- From: Jens Georg <jensgeorg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [rygel] server: Prevent critical on upload
- Date: Sat, 14 Jun 2014 20:50:06 +0000 (UTC)
commit 65965a0994f473885a0dfbf3e72385753125a316
Author: Jens Georg <mail jensge org>
Date: Sat Jun 14 22:30:30 2014 +0200
server: Prevent critical on upload
Signed-off-by: Jens Georg <mail jensge org>
src/librygel-server/rygel-media-art-store.vala | 8 ++++----
1 files changed, 4 insertions(+), 4 deletions(-)
---
diff --git a/src/librygel-server/rygel-media-art-store.vala b/src/librygel-server/rygel-media-art-store.vala
index 116be04..453c09c 100644
--- a/src/librygel-server/rygel-media-art-store.vala
+++ b/src/librygel-server/rygel-media-art-store.vala
@@ -59,7 +59,7 @@ public class Rygel.MediaArtStore : GLib.Object {
foreach (var type in types) {
file = this.get_media_art_file (type, item, simple);
- if (file.query_exists (null)) {
+ if (file != null && file.query_exists (null)) {
break;
} else {
file = null;
@@ -91,9 +91,9 @@ public class Rygel.MediaArtStore : GLib.Object {
return thumb;
}
- public File get_media_art_file (string type,
- MusicItem item,
- bool simple = false) {
+ public File? get_media_art_file (string type,
+ MusicItem item,
+ bool simple = false) {
File file;
MediaArt.get_file (item.artist,
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]