[comp.sources.bugs] Help with Mush/Ultrix 2.2 problem

lwv@n8emr.UUCP (Larry W. Virden) (05/17/88)

When I am using less version 2.2 and the latest mush, I find that occasionally
less is not in the proper reading mode at the bottom of the page.  For instance,
I type a ' ' tosee the next page and find that it just sits there.  If I type
a return, then both the space AND teh return is processed.  What is really
strange is that this only happens 15-20% of the time!  Typically it works just
fine.  Anyone have any ideas?

Also, another couple of questions:

Is there a switch that I can turn on for mush to output an EOT or some other
indicator that it is now processing my mail.  When I use /usr/ucb/Mail and type
^D, I get the EOT.

How can I get the Reply-To: header generated?

When I do a reply, I seldom get a usable address to reply to.  I often get
my own address, going back thru several other folks' machines as well as
an occasional other's address - but not in a form that my current machine can
handle.  Is there a section of the manual that I can read that can tell me how
to get addresses in bang format based from a feeding machine?  That is, if
my machine abc typically gets its mail from xyz, I would like replys to 
mail to appear to be 'xyz!your_mama!your_papa' rather than your_papa@your_mama.

-- 
Larry W. Virden	 75046,606 (CIS)
674 Falls Place, Reynoldsburg, OH 43068 (614) 864-8817
osu-cis!n8emr!lwv (UUCP)	osu-cis!n8emr!lwv@TUT.CIS.OHIO-STATE.EDU (BITNET)
We haven't inherited the world from our parents, but borrowed it from our children.

dheller@cory.Berkeley.EDU (Dan Heller) (05/18/88)

In article <554@n8emr.UUCP> lwv@n8emr.UUCP (Larry W. Virden) writes:
>When I am using less version 2.2 and the latest mush, I find that occasionally
>less is not in the proper reading mode at the bottom of the page.
The 62. patches that r$ is soon to post fixes the problem.  It was due
to a race condition in do_pager().  This is why it wasn't easily reproducible.
Since you can set your pager to any unix command (which is how you pipe
messages to unix commands), it could be that some unix commands require
some IO from the user in a normal tty state.  So, as a rule, whenever a
pipe or an exec of any kind is about to happen, I reset the tty state
from noecho/cbreak to echo_on/nocbreak.  Invoke the command (pager) and
then continue till it's done.  However, the pager could fail to open, so
I thought I was being clever by testing the return value of popen() before
I reset the tty modes.  thus:

    if (!(pp = popen(pager, "w")))
	error(pager);
    else
	echo_on();

The popen will fork and exec the pager and the parent will return a
file pointer.  If successful, the tty state was turned on.  Well, you
probably guessed where I went wrong.  If the pager happened to exec
before the echo_on() portion of the code happened, then the pager's
resetting of the tty states gets overridden by the program's setting
it to normal.  This race is usually won by the program, but when it's
not, you get the error you have experienced.

>Is there a switch that I can turn on for mush to output an EOT or some other
>indicator that it is now processing my mail.  When I use /usr/ucb/Mail and type
>^D, I get the EOT.
nope. sorry.  However, if you have either of the autosign variables set,
fortune or verbose mode, you shouldn't be too lost.  Just excuses... :-)

>How can I get the Reply-To: header generated?
you can use the my_hdr command:
my_hdr Reply-To: <address>
But the problem is, that address may not be correct for each user you
send to.  If you're using sendmail, you can reconfigure your sendmail.cf
to add this header.

>When I do a reply, I seldom get a usable address to reply to.  I often get
>my own address, going back thru several other folks' machines as well as
>an occasional other's address - but not in a form that my current machine can
>handle.  Is there a section of the manual that I can read that can tell me how
>to get addresses in bang format based from a feeding machine?  That is, if
>my machine abc typically gets its mail from xyz, I would like replys to 
>mail to appear to be 'xyz!your_mama!your_papa' rather than your_papa@your_mama.

See the variables section on the variables, known_hosts and auto_route.
Also, at the end of the manual, there is a short description of legal
addresses that might shed some light on the subject.  You can also use
the alternates command to filter out your own address if you don't want
to see your own login name.  unset "meeto" and type "alts *" to have mush
just look for your login name in an address.  If it exists, it removes
it from the list -- yes, this could introduce other problems, but it
generally doesn't.

>Larry W. Virden	 75046,606 (CIS)
>674 Falls Place, Reynoldsburg, OH 43068 (614) 864-8817


Dan Heller <island!argv@ucbcad.berkeley.edu>
	   <island!argv@sun.com>
	   <dheller@ucbcory.berkeley.edu>
			...dan