[rygel] core: Remove some uneeded checks
- From: Zeeshan Ali Khattak <zeeshanak src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [rygel] core: Remove some uneeded checks
- Date: Thu, 10 Dec 2009 18:08:22 +0000 (UTC)
commit e4549e0e5f158aff5459fb0bb12680d7ed352a66
Author: Zeeshan Ali (Khattak) <zeeshanak gnome org>
Date: Wed Dec 9 17:45:22 2009 +0200
core: Remove some uneeded checks
src/rygel/rygel-http-byte-seek.vala | 16 ++++------------
1 files changed, 4 insertions(+), 12 deletions(-)
---
diff --git a/src/rygel/rygel-http-byte-seek.vala b/src/rygel/rygel-http-byte-seek.vala
index 77b66ed..dd5b716 100644
--- a/src/rygel/rygel-http-byte-seek.vala
+++ b/src/rygel/rygel-http-byte-seek.vala
@@ -90,19 +90,11 @@ internal class Rygel.HTTPByteSeek : Rygel.HTTPSeek {
this.msg.response_headers.append ("Accept-Ranges", "bytes");
- range += start.to_string () + "-";
-
- if (stop >= 0.0) {
- range += stop.to_string ();
- }
-
- if (this.length > 0) {
- range += "/" + this.length.to_string ();
- } else {
- range += "/*";
- }
-
+ range += start.to_string () + "-" +
+ stop.to_string () + "/" +
+ this.length.to_string ();
this.msg.response_headers.append ("Content-Range", range);
+
this.msg.response_headers.set_content_length (this.length);
}
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]