[comp.windows.x] Xmh incorporate bug under sos4.1?

snyder@alphard.cs.utk.edu (Kim Snyder) (07/13/90)

Situation: sun3/60 running sos4.1 and X11R4
	   compiled with gcc.

Using Xmh to incorporate mail, the table of
contents adds an extra digit to the message
number.  For example;

 176  07/12 To:snyder          tesing <<>>
 177  07/12 To:snyder          testing <<>>
 178  07/12 To:snyder          testing <<>>
9179  07/12 To:snyder          <<>>
0180  07/12 To:snyder          testing mail<<mail from wham-o >>
1181  07/12 To:snyder          testing mail<<mail from wham-o >>
2182  07/12 To:snyder          testing mail<<mail from wham-o >>

A rescan will fix it.  I tried deleting .xmhcache, and 
that didn't do it.  .xmhcache reflects the bug.  However,
doing a "scan last:7" shows;

 176  07/12 To:snyder          tesing xmh<<>>
 177  07/12 To:snyder          testing inc<<>>
 178  07/12 To:snyder          testing inc<<>>
 179  07/12 To:snyder          <<>>
 180  07/12 To:snyder          testing mail<<mail from wham-o >>
 181  07/12 To:snyder          testing mail<<mail from wham-o >>
 182  07/12 To:snyder          testing mail<<mail from wham-o >>

The following are the compile options (using /bin/cc)
given to mh;

version: MH 6.7 #3[UCI] (cetus6a) of Wed Jul 11 18:28:12 EDT 1990
options: [BSD42] [BSD43] [TTYD] [SUN40] [TYPESIG=void] [MHE] [MHRC]
         [BIND] [SBACKUP='"#"'] [FOLDPROT='"0770"'] [NFS] [ATZ]
         [OVERHEAD] [SENDMTS] [SMTP]
 
Any help appreciated!

kim snyder

 

converse@EXPO.LCS.MIT.EDU (07/13/90)

> Situation: sun3/60 running sos4.1 and X11R4
> 	   compiled with gcc.
> 
> Using Xmh to incorporate mail, the table of
> contents adds an extra digit to the message
> number.  

This is due to a bug in gcc 1.38 which affects xmh.


Donna Converse

mark@comp.vuw.ac.nz (Mark Davies) (07/15/90)

In article <9007122144.AA02591@excess.lcs.mit.edu> converse@EXPO.LCS.MIT.EDU writes:
>> Using Xmh to incorporate mail, the table of
>> contents adds an extra digit to the message
>> number.  

>This is due to a bug in gcc 1.38 which affects xmh.

Actually I think Donna meant gcc 1.37.  Hopefully this bug should be fixed
in 1.38 as I reported it to bug-gcc when I first noticed it.

Here is the workaround I use in the meantime.

*** tocutil.c~	Fri Dec 15 15:20:04 1989
--- tocutil.c	Tue Apr  3 17:40:22 1990
***************
*** 576,582 ****
      msg->toc = toc;
      msg->buf = XtNewString(ptr);
      (void)sprintf(str, "%4d", msgid);
!     for (i=0; i<4 ; i++) msg->buf[i] = str[i];
      msg->buf[MARKPOS] = ' ';
      msg->msgid = msgid;
      msg->position = toc->lastPos;
--- 576,582 ----
      msg->toc = toc;
      msg->buf = XtNewString(ptr);
      (void)sprintf(str, "%4d", msgid);
!     for (i=4; i-- > 0 ;) msg->buf[i] = str[i];
      msg->buf[MARKPOS] = ' ';
      msg->msgid = msgid;
      msg->position = toc->lastPos;

cheers
mark

mgc@myshkin.udev.cdc.com (Mark G Christenson) (07/16/90)

In article <1990Jul12.192746.15832@cs.utk.edu>,
snyder@alphard.cs.utk.edu (Kim Snyder) writes:
|>Situation: sun3/60 running sos4.1 and X11R4
|>	   compiled with gcc.
|>
|>Using Xmh to incorporate mail, the table of
|>contents adds an extra digit to the message
|>number.  For example;
|>
|>  [example deleted]

This was reported on comp.windows.x as a bug in gcc 1.37.  The following
workaround for Xmh was posted by mark@comp.vuw.ac.nz (Mark Davies):

*** tocutil.c~  Fri Dec 15 15:20:04 1989
--- tocutil.c   Tue Apr  3 17:40:22 1990
***************
*** 576,582 ****
      msg->toc = toc;
      msg->buf = XtNewString(ptr);
      (void)sprintf(str, "%4d", msgid);
!     for (i=0; i<4 ; i++) msg->buf[i] = str[i];
      msg->buf[MARKPOS] = ' ';
      msg->msgid = msgid;
      msg->position = toc->lastPos;
--- 576,582 ----
      msg->toc = toc;
      msg->buf = XtNewString(ptr);
      (void)sprintf(str, "%4d", msgid);
!     for (i=4; i-- > 0 ;) msg->buf[i] = str[i];
      msg->buf[MARKPOS] = ' ';
      msg->msgid = msgid;
      msg->position = toc->lastPos;

Mark
                                        
Mark Christenson <mgc@myshkin.udev.cdc.com>
Control Data Corporation
Arden Hills, Minnesota

converse@EXPO.LCS.MIT.EDU (Donna Converse) (07/21/90)

On Thu, 12 Jul 90 17:44:41, I erroneously wrote:

>> Situation: sun3/60 running sos4.1 and X11R4
>> 	   compiled with gcc.
>> 
>> Using Xmh to incorporate mail, the table of
>> contents adds an extra digit to the message
>> number.  
>
> This is due to a bug in gcc 1.38 which affects xmh.


That should be gcc 1.37, (and reportedly, 1.37.1).
1.38 does not exist yet.


Donna Converse