home *** CD-ROM | disk | FTP | other *** search
/ InfoMagic Source Code 1993 July / THE_SOURCE_CODE_CD_ROM.iso / gnu / lucid / bug-lucid-emacs / text0024.txt < prev    next >
Encoding:
Text File  |  1993-07-04  |  3.6 KB  |  125 lines

  1. Hi there,
  2. the problem the RS6000 has with inserting slashes in funny places is
  3. due to the buggy insert_char function.  It has a char parameter to
  4. which a pointer is passed on to insert_raw_string.  Of course, this
  5. parameter is really an int, so this only works if the actual character
  6. is stored in the lower byte of 32-bit-words.  Since this is not the
  7. case on RS6000s, the whole thing goes berserk.  The following diff
  8. corrects the problem.  It also fixes the problem with
  9. undigestify-rmail-message, for instance.
  10.  
  11. Also, the AIX conditionals in the systime.h file are somewhat
  12. misplaced.  (They are inside other #ifdef's which don't get touched
  13. for the AIX config.)  So the patch for that is also included.  After
  14. this, things work just fine.
  15.  
  16. IMHO, these patches should make it into the standard distributions.
  17. The problems they fix are really bugs in Lucid Emacs.
  18.  
  19. Cheers =8-} Chipsy
  20.  
  21. --- snip, snip ---
  22.  
  23. *** insdel.c    Tue Apr 13 14:55:51 1993
  24. --- insdel.c.~1~    Mon Jan 11 19:41:15 1993
  25. ***************
  26. *** 515,522 ****
  27.   void
  28.   insert_char (char c)
  29.   {
  30. !   char tmp = c;
  31. !   insert_raw_string (&tmp, 1);
  32.   }
  33.   
  34.   /* Like `insert_raw_string' except that all markers pointing at the place where
  35. --- 515,521 ----
  36.   void
  37.   insert_char (char c)
  38.   {
  39. !   insert_raw_string (&c, 1);
  40.   }
  41.   
  42.   /* Like `insert_raw_string' except that all markers pointing at the place where
  43. *** systime.h    Mon Apr 12 20:51:14 1993
  44. --- systime.h.~1~    Mon Mar 15 10:36:40 1993
  45. ***************
  46. *** 33,45 ****
  47.   #include <time.h>
  48.   #endif /* _h_BSDTYPES */
  49.   
  50. - #endif
  51.   /* AIX needs both <sys/time.h> and <time.h>.  */
  52. ! #ifdef AIX
  53.   #include <time.h>
  54.   #endif
  55.   
  56.   
  57.   /* EMACS_TIME is the type to use to represent temporal intervals -
  58.      struct timeval on some systems, int on others.  It can be passed as
  59. --- 33,45 ----
  60.   #include <time.h>
  61.   #endif /* _h_BSDTYPES */
  62.   
  63.   /* AIX needs both <sys/time.h> and <time.h>.  */
  64. ! #ifdef _AIX
  65.   #include <time.h>
  66.   #endif
  67.   
  68. + #endif
  69.   
  70.   /* EMACS_TIME is the type to use to represent temporal intervals -
  71.      struct timeval on some systems, int on others.  It can be passed as
  72. ***************
  73. *** 194,201 ****
  74.       gettimeofday (&dummy, &zoneinfo);                    \
  75.       *(offset) = -zoneinfo.tz_minuteswest;                \
  76.     } while (0)
  77. ! #else /* ! defined (HAVE_TIMEVAL) */
  78.   
  79.   /* System V derivatives have a timezone global variable.  */
  80.   #ifdef USG
  81.   #define EMACS_GET_TZ_OFFSET(offset)                    \
  82. --- 194,202 ----
  83.       gettimeofday (&dummy, &zoneinfo);                    \
  84.       *(offset) = -zoneinfo.tz_minuteswest;                \
  85.     } while (0)
  86. ! #endif /* ! defined (HAVE_TIMEVAL) */
  87.   
  88.   /* System V derivatives have a timezone global variable.  */
  89.   #ifdef USG
  90.   #define EMACS_GET_TZ_OFFSET(offset)                    \
  91. ***************
  92. *** 205,212 ****
  93.     } while (0)
  94.   #endif
  95.   
  96. - #endif
  97.   /* The following sane systems have a tzname array.  The timezone() function
  98.      is a stupid idea; timezone names can only be determined geographically,
  99.      not by Greenwich offset.  */
  100. --- 206,211 ----
  101. ***************
  102. *** 249,256 ****
  103.                                       \
  104.       EMACS_GET_TIME (t);                            \
  105.       secs = EMACS_SECS (t);                        \
  106. !     tmp = localtime (&secs);                                            \
  107. !     *(savings_flag) = tmp->tm_isdst;                                \
  108.                                       \
  109.       EMACS_GET_TZ_OFFSET (offset);                    \
  110.       EMACS_GET_TZ_NAMES (standard, savings);                \
  111. --- 248,255 ----
  112.                                       \
  113.       EMACS_GET_TIME (t);                            \
  114.       secs = EMACS_SECS (t);                        \
  115. !     tmp = localtime (&secs);                        \
  116. !     *(savings_flag) = tmp->tm_isdst;                    \
  117.                                       \
  118.       EMACS_GET_TZ_OFFSET (offset);                    \
  119.       EMACS_GET_TZ_NAMES (standard, savings);                \
  120.  
  121.