Package: mgetty-fax Version: 1.2.1-1 Severity: normal Dear Andreas,
I tried using @DATE +format@ in my fax header (~/.faxheader), but always got the default 'date' output instead. It appears that the escaping of a plus sign in /usr/bin/faxspool, in conjunction with GNU sed, might be causing this. My ~/.faxheader looks like this: @DATE +%m/%d %Y %R@ @ID@ @N@ (@U@) -> @D@ (@T@) PAGE @P@/@M@ Expected FDATE variable contents (see below) would be something like: 05/17 2021 20:54 Instead I got an empty FDATE variable, and hence, the default output of the 'date' command instead; something like: mån 17 maj 2021 20:57:40 CEST Suggested change (unified diff): --- /usr/bin/faxspool 2018-10-06 22:17:07.000000000 +0200 +++ ./faxspool.NEW 2021-05-17 20:48:40.110235800 +0200 @@ -938,7 +938,7 @@ if [ -n "$FAX_HEADER" ] then # flexible DATE format - FDATE=`sed -n -e '\!@DATE \+[0-9a-zA-Z: \./%\-]*@!s!.*@DATE \(\+[0-9a-zA-Z: \./%\-]*\)@.*!\1!p' $FAX_HEADER` + FDATE=`sed -n -e '\!@DATE +[0-9a-zA-Z: \./%\-]*@!s!.*@DATE \(\+[0-9a-zA-Z: \./%\-]*\)@.*!\1!p' $FAX_HEADER` if [ -n "$FDATE" ] ; then DATE_OUT=`date "$FDATE"` else Some searching yielded this: https://stackoverflow.com/a/63940155 Might this be the explanation? And, would the removal of the escaping cause problems for those not using GNU sed? Many thanks in advance! Best regards Björn -- System Information: Debian Release: 10.9 APT prefers stable-updates APT policy: (500, 'stable-updates'), (500, 'stable') Architecture: amd64 (x86_64) Kernel: Linux 4.19.0-16-amd64 (SMP w/4 CPU cores) Locale: LANG=en_US.UTF-8, LC_CTYPE=sv_SE.UTF-8 (charmap=UTF-8), LANGUAGE=en_US:en (charmap=UTF-8) Shell: /bin/sh linked to /usr/bin/dash Init: systemd (via /run/systemd/system) LSM: AppArmor: enabled Versions of packages mgetty-fax depends on: ii cron 3.0pl1-134+deb10u1 ii debconf [debconf-2.0] 1.5.71 ii libc6 2.28-10 ii mgetty 1.2.1-1 ii perl 5.28.1-6+deb10u1 mgetty-fax recommends no packages. Versions of packages mgetty-fax suggests: ii debianutils 4.8.6.1 ii ghostscript 9.27~dfsg-2+deb10u4 pn mgetty-viewfax <none> ii netpbm 2:10.0-15.3+b2 -- Configuration Files: /etc/mgetty/new_fax changed [not included] -- debconf information: mgetty-fax/start_faxrunqd: true