Bug 17538 - calls mailx from Firefox in a bad way
: calls mailx from Firefox in a bad way
Status: CLOSED FIXED
: Branch 4.0
(All bugs in Branch 4.0/url_handler)
: 4.0
: all Linux
: P2 critical
Assigned To:
:
:
:
:
:
  Show dependency tree
 
Reported: 2008-10-12 23:53 by
Modified: 2010-11-24 08:10 (History)


Attachments


Note

You need to log in before you can comment on or make changes to this bug.


Description From 2008-10-12 23:53:48
url_handler-0.3.0-alt1

In Lite 4.0.3, if you press on a "mailto" link in Firefox, an undesirable thing
happens: (only the last handler is available, it's mailx) mailx is not run in a
terminal, so it has no input, and as a result, it even not merely fails, but
rather sends some message (empty? or whatever -- that's not important) without
your consent to send it.

Probably, that's either because the specification

'/usr/bin/mailx --':VT

in /etc/urlview/url_handlers has un unsuitable mode (VT: Launch in the same
terminal) or because the VT mode is not handled correctly in the script (it
shouldn't be started if there is no interactive input).

The latter thing must be fixed: a VT program shouldn't be run with no
interactive input: so either it should forcibly run in an xterm in such case,
or it should simply fail.

As for the first thing, I don't know whether XT would indeed be a better mode
for mailx.
------- Comment #1 From 2008-10-13 00:45:54 -------
What happens:

$ mailx -v -- imz < /dev/null
No message, no subject; hope that's ok
Mail Delivery Status Report will be mailed to <imz>.
$ 
------- Comment #2 From 2008-10-13 00:49:30 -------
One more possible workaround/solution/enhancement: call mailx in url_handlers
in a forced interactive mode; then it will fail in such cases:

$ mailx -v -I -- imz < /dev/null
mailx: tcgetattr: Inappropriate ioctl for device
$ 

But that won't solve the problem of sending mail from Firefox when no other
mailers are available. So, there is still need for some modification, such that
xterm will be used in such cases.
------- Comment #3 From 2008-10-18 20:00:11 -------
<a href="mailto:imz@example.com">An example link</a> to press in Firefox (which
generates an empty message).

Another way to reproduce: right click, and "Send" in the menu. It generates an
empty message to nowhere. (See postfix logs.)
------- Comment #4 From 2010-11-24 05:14:43 -------
url_handler-0.3.1-alt1 -> sisyphus:

* Wed Nov 24 2010 Dmitry V. Levin <ldv@altlinux> 0.3.1-alt1
- url_handler.sh: added "mailto" type autodetection (closes: #24627).
- url_handlers: changed mailx mode to XT (closes: #17538).
- url_handler.sh: treat BROWSER and MAILER environment variables as
  colon-separated lists without necessary full path (closes: #3482).