Re: Fresh install misses autostart of daemon and faxgetty

Lee Howard <[email protected]> Wed, 5 Dec 2018 16:10:39 -0800
Newsgroups gmane.comp.telephony.fax.hylafax.user
Message-ID <[email protected]>
On 12/05/2018 03:12 AM, Carsten wrote:
> For some strange reason, the subject in the sent report is still
> displayed in UTF-8 code.

The sent report (from HylaFAX's notify) subject line will depend on how
you're submitting the fax.=C2=A0 I think that you said you're using
mail2fax.=C2=A0 If you mean to say that you're using this mail2fax script=
:

http://hylafax.sourceforge.net/howto/misc/mail2fax.sh

... then part of the trouble is that mail2fax script is not decoding the
RFC-2047-encoded subject line from the original mail.=C2=A0 It's only doi=
ng this:

JOBID=3D`grep -e "^subject:" -i $RANDOMFAX/_message_ | sed q | sed
's/^[^:]*: *//g'`

So, it's just extracting the subject line from the source email but is
not decoding it at all.

Not for lack of trying, but I can't seem to find any competent
command-line program to do that decoding, so I've made another change to
faxmail to produce that output:

https://sourceforge.net/p/hylafax/HylaFAX+/2481/

Once you update your faxmail with this change then if you're using the
mentioned mail2fax script you'd want to change the line that says:

cat $RANDOMFAX/_message_ | faxmail -v -T $FROMPATH | sendfax -vv -n -D
-f "$FROMPATH" -i "$JOBID" -d $TONUMBER

... into something like this:

cat $RANDOMFAX/_message_ | faxmail -v -T $FROMPATH >
$RANDOMFAX/faxmail_stdout 2> $RANDOMFAX/faxmail_stderr
JOBID2=3D"`cat $RANDOMFAX/faxmail_stderr | grep -a "^DECODED Subject:" |
sed 's/^DECODED Subject: //g'`"
if [ -n "$JOBID2" ]; then JOBID=3D"$JOBID2"; fi
cat $RANDOMFAX/faxmail_stdout | sendfax -vv -n -D -f "$FROMPATH" -i
"$JOBID" -d $TONUMBER

That will get the decoded data into the job file.=C2=A0 From there, thoug=
h,
it's going to depend on your configuration of "FaxNotify" as Bodo
suggested.=C2=A0 It still could get messed up after that.=C2=A0 Also, all=
 that
this really does is to stick the raw data into the jobid field in the
job... the character encoding isn't defined.=C2=A0 Again, it's really goi=
ng
to depend on your "notify" configuration... however the default notify
doesn't decode strings encoded with RFC-2047.

Thanks,

Lee.


____________________ HylaFAX(tm) Users Mailing List _____________________=
__
  To subscribe/unsubscribe, click http://lists.hylafax.org/cgi-bin/lsg2.c=
gi
 On UNIX: mail -s unsubscribe [email protected] < /dev/nu=
ll
  *To learn about commercial HylaFAX(tm) support, mail [email protected].*