Package: w-scan-cpp
X-Debbugs-Cc: [email protected]
Version: 20231015+dfsg-3+b1
Severity: normal
Tags: patch

Dear Maintainer,

I tried creating a xspf file for use with VLC like this (DVB-S, Astra 19.2E):

    w_scan_cpp -f s -c DE -s S19E2 --output-VLC | tee -a vlc-dvb.xspf

Unfortunately the resulting file contains frequencies in MHz,
while VLC expects, at least the version in trixie, the frequency in Hz.

Applying following patch below to w-scan-cpp produces a file that is understood 
by VLC.

Kind regards,
Bernhard



diff --git a/OutputFormats.cpp b/OutputFormats.cpp
index 8488744..f2af824 100644
--- a/OutputFormats.cpp
+++ b/OutputFormats.cpp
@@ -927,10 +927,10 @@ void PrintVLC(std::vector<TChannel>& List) {
         ss << INDENT << "</extension>" << std::endl;
         }
      if (c.Source.find('S') == 0) {
-        uint32_t freq_MHz = c.Frequency;
+        uint64_t freq_MHz = c.Frequency;
         ss << INDENT << "<location>dvb-s";
         if (c.DelSys == 1) ss << "2";
-        ss << "://frequency=" << freq_MHz << "</location>" << std::endl;
+        ss << "://frequency=" << (freq_MHz * (uint64_t)1000000) << "</location>" 
<< std::endl;
ss << INDENT << "<extension" << " application=" << '"' << AppUrl << '"' << ">" << std::endl;
         indent++;





-- System Information:
Debian Release: 13.2
  APT prefers stable-updates
  APT policy: (500, 'stable-updates'), (500, 'stable-security'), (500, 
'stable-debug'), (500, 'proposed-updates-debug'), (500, 'proposed-updates'), 
(500, 'stable')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 6.12.57+deb13-amd64 (SMP w/16 CPU threads; PREEMPT)
Kernel taint flags: TAINT_OOT_MODULE, TAINT_UNSIGNED_MODULE
Locale: LANG=de_DE.UTF-8, LC_CTYPE=de_DE.UTF-8 (charmap=UTF-8), LANGUAGE not set
Shell: /bin/sh linked to /usr/bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled

Versions of packages w-scan-cpp depends on:
ii  libc6            2.41-12
ii  libcurl4t64      8.14.1-2+deb13u2
ii  libfontconfig1   2.15.0-2.3
ii  libfreetype6     2.13.3+dfsg-1
ii  libgcc-s1        14.2.0-19
ii  libjpeg62-turbo  1:2.1.5-4
ii  libpugixml1v5    1.14-2
ii  librepfunc1      1.10.0-1
ii  libstdc++6       14.2.0-19

w-scan-cpp recommends no packages.

w-scan-cpp suggests no packages.

-- no debconf information

Reply via email to