]> git.ipfire.org Git - thirdparty/tvheadend.git/commitdiff
HTSP: Expose recording files' start and stop time.
authorKai Sommerfeld <kai.sommerfeld@gmx.com>
Wed, 3 Jan 2018 13:57:24 +0000 (14:57 +0100)
committerJaroslav Kysela <perex@perex.cz>
Fri, 5 Jan 2018 09:35:24 +0000 (10:35 +0100)
src/htsp_server.c

index 76a64e3dfc143aee9bcbc3656e05949bad6eefbf..21148984c527838d93c69dc0f6ba3425b305c715 100644 (file)
@@ -932,7 +932,7 @@ htsp_build_dvrentry(htsp_connection_t *htsp, dvr_entry_t *de, const char *method
   htsmsg_field_t *f;
   const char *s = NULL, *error = NULL, *subscriptionError = NULL;
   const char *p, *last;
-  int64_t fsize = -1;
+  int64_t fsize = -1, start, stop;
   uint32_t u32;
   char ubuf[UUID_HEX_SIZE];
 
@@ -1005,6 +1005,11 @@ htsp_build_dvrentry(htsp_connection_t *htsp, dvr_entry_t *de, const char *method
           info = htsmsg_get_list(m, "info");
           if (info)
             htsmsg_set_msg(e, "info", htsmsg_copy(info));
+          if (!htsmsg_get_s64(m, "start", &start))
+            htsmsg_set_s64(e, "start", start);
+          if (!htsmsg_get_s64(m, "stop", &stop))
+            htsmsg_set_s64(e, "stop", stop);
+
           htsmsg_add_msg(l, NULL, e);
         }
       }