Diff for /freem/src/global_dispatch.c between versions 1.4 and 1.8

version 1.4, 2025/03/09 19:14:25 version 1.8, 2025/04/09 19:52:02
Line 24 Line 24
  *   along with FreeM.  If not, see <https://www.gnu.org/licenses/>.   *   along with FreeM.  If not, see <https://www.gnu.org/licenses/>.
  *   *
  *   $Log$   *   $Log$
    *   Revision 1.8  2025/04/09 19:52:02  snw
    *   Eliminate as many warnings as possible while building with -Wall
    *
    *   Revision 1.7  2025/04/09 15:16:50  snw
    *   Fix buffer overruns in mref_to_external and ssvn.c
    *
    *   Revision 1.6  2025/03/29 16:50:42  snw
    *   Back to cvs-current as version for development; temp fix for double-free issue in global_dispatch
    *
    *   Revision 1.5  2025/03/24 04:13:11  snw
    *   Replace action macro dat with fra_dat to avoid symbol conflict on OS/2
    *
  *   Revision 1.4  2025/03/09 19:14:25  snw   *   Revision 1.4  2025/03/09 19:14:25  snw
  *   First phase of REUSE compliance and header reformat   *   First phase of REUSE compliance and header reformat
  *   *
Line 53  void (*gbl_s)(short, char *, char *); Line 65  void (*gbl_s)(short, char *, char *);
   
 void global_set_engine(char ns, char *engine)  void global_set_engine(char ns, char *engine)
 {  {
                               
           if (strcmp (engine, "BUILTIN") != 0) {
     if ((strcmp (engine, "BUILTIN") != 0) && (strcmp (engine, "BERKELEYDB") != 0)) {  
   
         if (strcmp (engine, "NICKELBACK") == 0) {  
             char *j;  
             printf ("\r\nERROR:  please go burn your CD collection in fire. Here, have a segfault...\r\n");  
   
             j[2] = '\201';  
         }  
           
         printf ("\r\nERROR:  '%s' is not a valid global storage engine\r\n", engine);          printf ("\r\nERROR:  '%s' is not a valid global storage engine\r\n", engine);
         merr_raise (M38);          merr_raise (M38);
                   
Line 192  void global (short action, char *key, ch Line 196  void global (short action, char *key, ch
         name[i] = '\0';          name[i] = '\0';
                   
         snprintf (mapk_buf, STRLEN - 1, "^$SYSTEM\202MAPPINGS\202GLOBAL\202%s\201", name);          snprintf (mapk_buf, STRLEN - 1, "^$SYSTEM\202MAPPINGS\202GLOBAL\202%s\201", name);
         global (get_sym, mapk_buf, mapd_buf);          symtab_shm (get_sym, mapk_buf, mapd_buf);
   
         stcnv_m2c (mapd_buf);          stcnv_m2c (mapd_buf);
                   
Line 424  void global (short action, char *key, ch Line 428  void global (short action, char *key, ch
             case get_sym:              case get_sym:
                 sprintf (an, "GET");                  sprintf (an, "GET");
                 break;                  break;
             case dat:              case fra_dat:
                 sprintf (an, "DATA");                  sprintf (an, "DATA");
                 break;                  break;
             case fra_order:              case fra_order:
Line 466  void global (short action, char *key, ch Line 470  void global (short action, char *key, ch
         evt_enqueue (ev_id, EVT_CLS_TRIGGER, 0);          evt_enqueue (ev_id, EVT_CLS_TRIGGER, 0);
   
         free (k_buf);          free (k_buf);
         free (d_buf);          /* free (d_buf); */
     }        }  
           
     free (old_value);      free (old_value);

Removed from v.1.4  
changed lines
  Added in v.1.8


FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>