Diff for /freem/src/iniconf.c between versions 1.5 and 1.8

version 1.5, 2025/04/09 19:52:02 version 1.8, 2025/04/10 15:31:25
Line 25 Line 25
  *   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/10 15:31:25  snw
    *   Attempt to fix DosCopy calls for OS/2
    *
    *   Revision 1.7  2025/04/10 15:27:39  snw
    *   Detect Devuan distribution and fix OS/2 problem with iniconf.c
    *
    *   Revision 1.6  2025/04/10 01:24:38  snw
    *   Remove C++ style comments
    *
  *   Revision 1.5  2025/04/09 19:52:02  snw   *   Revision 1.5  2025/04/09 19:52:02  snw
  *   Eliminate as many warnings as possible while building with -Wall   *   Eliminate as many warnings as possible while building with -Wall
  *   *
Line 53 Line 62
 #include <fs.h>  #include <fs.h>
 #include "mpsdef.h"  #include "mpsdef.h"
   
   #if defined(__OS2__)
   # include <os2.h>
   #endif
   
 extern char config_file[4096];  extern char config_file[4096];
   
 #if !defined(PATH_MAX) && defined(_SCO_DS)  #if !defined(PATH_MAX) && defined(_SCO_DS)
Line 71  extern char config_file[4096]; Line 84  extern char config_file[4096];
 # include <sys/syslimits.h>  # include <sys/syslimits.h>
 #endif  #endif
   
   #if !defined(PATH_MAX)
   # define PATH_MAX 4096
   #endif
   
   
 /* ini_keyvalue *ini_head; */  /* ini_keyvalue *ini_head; */
   
 int get_conf(char *section, char *key, char *value)  int get_conf(char *section, char *key, char *value)
Line 197  int read_profile_string(char *file, char Line 215  int read_profile_string(char *file, char
     char *cursec;      char *cursec;
     char *line;      char *line;
     int lnum = 0;      int lnum = 0;
   
       curkey = (char *) NULL;
           
     fullsec = (char *) malloc(CONF_BUFSIZE);      fullsec = (char *) malloc(CONF_BUFSIZE);
     NULLPTRCHK(fullsec,"read_profile_string");      NULLPTRCHK(fullsec,"read_profile_string");
Line 364  int modify_profile_string(char *file, ch Line 384  int modify_profile_string(char *file, ch
 #if !defined(__OS2__)  #if !defined(__OS2__)
     cp (file, output_filename);      cp (file, output_filename);
 #else  #else
     DosCopy (output_filename, file);      DosCopy (output_filename, file, 1);
 #endif      #endif    
                                                 
     return changed;      return changed;

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


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