[rygel] core: Non-native files are not writable
- From: Jens Georg <jensgeorg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [rygel] core: Non-native files are not writable
- Date: Thu, 19 May 2011 16:28:03 +0000 (UTC)
commit 8d2f2a08f3e0e2229a52d6f6c28bf0cb2dbcb882
Author: Jens Georg <mail jensge org>
Date: Thu May 19 16:22:42 2011 +0200
core: Non-native files are not writable
src/rygel/rygel-media-object.vala | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
---
diff --git a/src/rygel/rygel-media-object.vala b/src/rygel/rygel-media-object.vala
index ff3ab06..357f45d 100644
--- a/src/rygel/rygel-media-object.vala
+++ b/src/rygel/rygel-media-object.vala
@@ -180,6 +180,10 @@ public abstract class Rygel.MediaObject : GLib.Object {
private async bool check_writable (File file, Cancellable? cancellable)
throws Error {
+ if (!file.is_native ()) {
+ return false;
+ }
+
try {
var info = yield file.query_info_async (
FILE_ATTRIBUTE_ACCESS_CAN_WRITE,
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]