]> git.ipfire.org Git - thirdparty/tvheadend.git/commitdiff
Add --nohdhomerun flag to disable HDHomeRun client initialization
authorcopilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Sun, 5 Oct 2025 20:41:37 +0000 (20:41 +0000)
committercopilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Sun, 5 Oct 2025 20:41:37 +0000 (20:41 +0000)
Co-authored-by: Flole998 <9951871+Flole998@users.noreply.github.com>
src/input/mpegts.c
src/input/mpegts.h
src/main.c

index fca4f34296a5433d01f2a039eff53bbf07a3cb57..441ced66998799f9f15f9a2ed815ae3e908e0574 100644 (file)
@@ -26,8 +26,8 @@ extern memoryinfo_t mpegts_input_queue_memoryinfo;
 extern memoryinfo_t mpegts_input_table_memoryinfo;
 
 void
-mpegts_init ( int linuxdvb_mask, int nosatip, str_list_t *satip_client,
-              str_list_t *tsfiles, int tstuners )
+mpegts_init ( int linuxdvb_mask, int nosatip, int nohdhomerun,
+              str_list_t *satip_client, str_list_t *tsfiles, int tstuners )
 {
   /* Register classes (avoid API 400 errors due to not yet defined) */
   idclass_register(&mpegts_network_class);
@@ -80,7 +80,8 @@ mpegts_init ( int linuxdvb_mask, int nosatip, str_list_t *satip_client,
 
  /* HDHomerun client */
 #if ENABLE_HDHOMERUN_CLIENT
-  tvhdhomerun_init();
+  if (!nohdhomerun)
+    tvhdhomerun_init();
 #endif
 
   /* Mux schedulers */
index 0fb5b192279f0dceb963b26f9a21d91ba3e1a915..2f6e504450a46ea12c8c3180354b5fa5c8083aa6 100644 (file)
@@ -75,8 +75,8 @@ extern const idclass_t mpegts_input_class;
  * Setup / Tear down
  * *************************************************************************/
 
-void mpegts_init ( int linuxdvb_mask, int nosatip, str_list_t *satip_client,
-                   str_list_t *tsfiles, int tstuners );
+void mpegts_init ( int linuxdvb_mask, int nosatip, int nohdhomerun,
+                   str_list_t *satip_client, str_list_t *tsfiles, int tstuners );
 void mpegts_done ( void );
 
 /* **************************************************************************
index fa3a335d5fa3e0f1b504ec442f9bb74e88f3b2cd..7ed10c27cdfeaaf0302223f26d884eb63d8038f4 100644 (file)
@@ -846,6 +846,7 @@ main(int argc, char **argv)
               opt_libav        = 0,
               opt_ipv6         = 0,
               opt_nosatipcli   = 0,
+              opt_nohdhomerun  = 0,
               opt_satip_rtsp   = 0,
 #if ENABLE_TSFILE
               opt_tsfile_tuner = 0,
@@ -919,6 +920,10 @@ main(int argc, char **argv)
       OPT_BOOL, &opt_nosatipcli },
     {   0, "satip_xml",  N_("URL with the SAT>IP server XML location"),
       OPT_STR_LIST, &opt_satip_xml },
+#endif
+#if ENABLE_HDHOMERUN_CLIENT
+    {   0, "nohdhomerun",    N_("Disable HDHomeRun client"),
+      OPT_BOOL, &opt_nohdhomerun },
 #endif
     {   0, NULL,         N_("Server connectivity"),    OPT_BOOL, NULL         },
     { '6', "ipv6",       N_("Listen on IPv6"),         OPT_BOOL, &opt_ipv6    },
@@ -1310,8 +1315,8 @@ main(int argc, char **argv)
   tvhftrace(LS_MAIN, descrambler_init);
   tvhftrace(LS_MAIN, dvb_init);
 #if ENABLE_MPEGTS
-  tvhftrace(LS_MAIN, mpegts_init, adapter_mask, opt_nosatipcli, &opt_satip_xml,
-            &opt_tsfile, opt_tsfile_tuner);
+  tvhftrace(LS_MAIN, mpegts_init, adapter_mask, opt_nosatipcli, opt_nohdhomerun,
+            &opt_satip_xml, &opt_tsfile, opt_tsfile_tuner);
 #endif
   tvhftrace(LS_MAIN, channel_init);
   tvhftrace(LS_MAIN, bouquet_service_resolve);