Index: elm2.4.ME+.123a-cvs/hdrs/patchlevel.h Prereq: 1183600000 *** elm2.4.ME+.123/hdrs/patchlevel.h Wed Jul 5 20:21:50 2006 --- elm2.4.ME+.123a-cvs/hdrs/patchlevel.h Wed Jul 26 11:29:30 2006 *************** *** 1,8 **** ! #define PATCHLEVEL "123" /* Used by Configure: SHAREDTAG: .1.0.123 */ ! #define LAST_REPORT_TIME 1183600000 #define BUG_REPORT_ADDR "Kari Hurtta " #define VERS_DATE "Jul 2006" /* for elm -v option */ #define WHAT_STRING \ --- 1,8 ---- ! #define PATCHLEVEL "123a (25)" /* Used by Configure: SHAREDTAG: .1.0.123 */ ! #define LAST_REPORT_TIME 1183700000 #define BUG_REPORT_ADDR "Kari Hurtta " #define VERS_DATE "Jul 2006" /* for elm -v option */ #define WHAT_STRING \ Index: elm2.4.ME+.123a-cvs/README.ME+ *** elm2.4.ME+.123/README.ME+ Wed Jul 5 20:21:50 2006 --- elm2.4.ME+.123a-cvs/README.ME+ Thu Jul 27 18:06:10 2006 *************** *** 1,4 **** ! $Header: /home/users/hurtta/cvsroot/mail/elmme+/README.ME+,v 1.1116 2006/07/05 15:36:25 hurtta Exp $ Version Elm2.4ME+ PL0 (25) is based on version Elm2.4 PL24 ME8b+. Version Elm2.4 PL24 ME8b+ is based on version Elm2.4 PL24 ME8b. --- 1,4 ---- ! $Header: /home/users/hurtta/cvsroot/mail/elmme+/README.ME+,v 1.1127 2006/07/27 15:06:10 hurtta Exp $ Version Elm2.4ME+ PL0 (25) is based on version Elm2.4 PL24 ME8b+. Version Elm2.4 PL24 ME8b+ is based on version Elm2.4 PL24 ME8b. *************** *** 13,18 **** --- 13,41 ---- Version Elm2.4 PL24 ME8b is based on version Elm2.4 PL24. Version Elm2.4ME+ PLx (25) includes patch of version Elm2.4 PL25. + Changes of Elm 2.4ME+ PL123a (25) compared with Elm 2.4ME+ PL123 (25) + --------------------------------------------------------------------- + + - "Looking at my incoming mail I noticed that there is no + space (empty line) between the end of one message and the + beginning of the next message". + Reported by: Noam G. Nudelman + > This is regression of Elm 2.4ME+ PL123 (25) or + Elm 2.4ME+ PL122j (25). With IMAP fix from 122j + content length does not include ending empty line of mail. + Fixed mbx_mark_keep_normal() for that. + WARNING: On MMDF case mbx_mark_keep_normal() is not fixed + and is probably broken. + + - Patchlevel variable for PL 123 (25) did not included (25). + Re-added it, because it is still other places. Perhaps that + (25) should be removed. It have little point. + + - elm.rc may include 'unidata = none'. Avoid failing of + 'elmregister replay' because of chmod is failing. + > Instead do chmod on elmunidata + - Same also for 'bindata = none' (do chmod on elmunidata). + Changes of Elm 2.4ME+ PL123 (25) compared with Elm 2.4ME+ PL122 (25) -------------------------------------------------------------------- *************** *** 195,201 **** - Changed implementation of elmrc option "pgp5-dir". - Changed implementation of elmrc option "print". ! - Fix expansive debug loop on imap.c (so that loop is not run if dubugging is not used.) - Moved some code from lib/charset.c to lib/mparse.c --- 218,224 ---- - Changed implementation of elmrc option "pgp5-dir". - Changed implementation of elmrc option "print". ! - Fix expensive debug loop on imap.c (so that loop is not run if dubugging is not used.) - Moved some code from lib/charset.c to lib/mparse.c *************** *** 209,219 **** - On batch mode standard input is read for mail only when -i (include file) option is not given. - Added mp_list_set_anon() and mp_lookup_anon() to src/screen/menu_param.c. ! - some cleanup on mailsmg1() - Changed default of elmrc variable "names" to NO --- 232,244 ---- - On batch mode standard input is read for mail only when -i (include file) option is not given. + (but actually -i option is not allowed on batch + mode.) - Added mp_list_set_anon() and mp_lookup_anon() to src/screen/menu_param.c. ! - some cleanup on mailmsg1() - Changed default of elmrc variable "names" to NO *************** *** 303,309 **** - RFC 2192 says that native separator of imap is used as hierarchy separator. This implementation accepts URL separator (/) as hierarcy separator ! (even when natice separator differ.) - Numbers 0-9 are also valid for imap atom. Not need to convert parameter to string or literal. --- 328,334 ---- - RFC 2192 says that native separator of imap is used as hierarchy separator. This implementation accepts URL separator (/) as hierarcy separator ! (even when native separator differ.) - Numbers 0-9 are also valid for imap atom. Not need to convert parameter to string or literal. *************** *** 416,422 **** - Some code changes on src/messages/ - Moved show_message_status from lib/mbox/mbox.c (originally from src/screen.c) ! to src/message/status_common.c - Moved status handling from src/menu_common/mailbox.c to src/messages/status_common.c. Routines on src/menu_common/mailbox.c does just forwarding. --- 441,447 ---- - Some code changes on src/messages/ - Moved show_message_status from lib/mbox/mbox.c (originally from src/screen.c) ! to src/messages/status_common.c - Moved status handling from src/menu_common/mailbox.c to src/messages/status_common.c. Routines on src/menu_common/mailbox.c does just forwarding. *************** *** 632,641 **** "readmsg | {print-command}". It was disabled on PL98 because it printed raw mime data. Because readmsg no longer outputs raw mime data, p)rint command can be enabled again. ! However, it is quite useless. p)rint command now acst as P)rint text -command. - - If "store" is given to elmrc option "show-header-errors", header errors are not immediately printed. Letter 'h' is shown as second status letter on that case. --- 657,665 ---- "readmsg | {print-command}". It was disabled on PL98 because it printed raw mime data. Because readmsg no longer outputs raw mime data, p)rint command can be enabled again. ! However, it is quite useless. p)rint command now acts as P)rint text -command. - If "store" is given to elmrc option "show-header-errors", header errors are not immediately printed. Letter 'h' is shown as second status letter on that case. *************** *** 686,693 **** - Allow setting "sentmail" elmrc option (normally "=sent") to "none". When "sentmail" is set to "none", ! "<" can not usedd as folder name. ! - If "sendmail" is set to "none", "copy" defaults to OFF. - Fix (or work around) error --- 710,717 ---- - Allow setting "sentmail" elmrc option (normally "=sent") to "none". When "sentmail" is set to "none", ! "<" can not used as folder name. ! - If "sentmail" is set to "none", "copy" defaults to OFF. - Fix (or work around) error Index: elm2.4.ME+.123a-cvs/Makefile-1.SH *** elm2.4.ME+.123/Makefile-1.SH Wed Jul 5 20:21:50 2006 --- elm2.4.ME+.123a-cvs/Makefile-1.SH Thu Jul 27 18:06:10 2006 *************** *** 27,33 **** echo "Extracting Makefile-1 (with variable substitutions)" cat >Makefile-1 <Makefile-1 < (was hurtta+elm@ozone.FMI.FI) *****************************************************************************/ --- 1,7 ---- ! /* $Id: elmlib.h,v 1.272 2006/07/24 18:44:58 hurtta Exp $ */ /****************************************************************************** ! * The Elm (ME+) Mail System - $Revision: 1.272 $ $State: Exp $ * * Author: Kari Hurtta (was hurtta+elm@ozone.FMI.FI) *****************************************************************************/ *************** *** 96,103 **** /* lib/strmcpy.c */ ! extern char *strmcpy P_((char *, CONST char *)); ! extern char *strmcat P_((char *, CONST char *)); /* safeopen.c */ --- 96,103 ---- /* lib/strmcpy.c */ ! extern char *strmcpy P_((char *, const char *)); ! extern char *strmcat P_((char *, const char *)); /* safeopen.c */ *************** *** 106,112 **** /* istrcmp.c */ ! extern int istrcmp P_((CONST char *, CONST char *)); /* add_site.c */ --- 106,112 ---- /* istrcmp.c */ ! extern int istrcmp P_((const char *, const char *)); /* add_site.c */ *************** *** 151,157 **** /* can_open.c */ ! extern int can_open P_((CONST char *, CONST char *)); /* chloc.c */ --- 151,157 ---- /* can_open.c */ ! extern int can_open P_((const char *, const char *)); /* chloc.c */ *************** *** 199,213 **** /* expand.c */ extern int expand P_((char *, int)); ! extern int expand_env P_((char *dest, CONST char *src,unsigned destlen)); ! extern int expand_meta P_((char *dest, CONST char *src,unsigned destlen)); /* expand_path is subset of expand_env and expand_meta Returns 0 if no expansion done 1 if expansion done -1 on failure */ ! extern int expand_path P_((char *dest, CONST char *src, unsigned destlen)); /* gcos_name.c */ --- 199,213 ---- /* expand.c */ extern int expand P_((char *, int)); ! extern int expand_env P_((char *dest, const char *src,unsigned destlen)); ! extern int expand_meta P_((char *dest, const char *src,unsigned destlen)); /* expand_path is subset of expand_env and expand_meta Returns 0 if no expansion done 1 if expansion done -1 on failure */ ! extern int expand_path P_((char *dest, const char *src, unsigned destlen)); /* gcos_name.c */ *************** *** 224,235 **** extern void free_rfc822tokenized P_((char **res)); /* Removes comments from vector: */ extern void remove_space_tokenized P_((char ** tokenized)); ! extern char **rfc822_tokenize P_((CONST char *line)); typedef struct charcode_info * charset_t; extern int look_special_tokens P_((char **tokenized, ! CONST char *tok_chars, int start, int *ended, int demime, charset_t set, struct string **comments, --- 224,235 ---- extern void free_rfc822tokenized P_((char **res)); /* Removes comments from vector: */ extern void remove_space_tokenized P_((char ** tokenized)); ! extern char **rfc822_tokenize P_((const char *line)); typedef struct charcode_info * charset_t; extern int look_special_tokens P_((char **tokenized, ! const char *tok_chars, int start, int *ended, int demime, charset_t set, struct string **comments, *************** *** 243,249 **** struct string *fullname; struct string *comment; } ! * break_down_address P_((CONST char *buffer, int demime, charset_t defcharset)); extern void free_addr_items P_((struct addr_item *list)); --- 243,249 ---- struct string *fullname; struct string *comment; } ! * break_down_address P_((const char *buffer, int demime, charset_t defcharset)); extern void free_addr_items P_((struct addr_item *list)); *************** *** 319,325 **** /* len_next.c */ ! extern int len_next_part P_((CONST char *)); /* mail_gets.c */ --- 319,325 ---- /* len_next.c */ ! extern int len_next_part P_((const char *)); /* mail_gets.c */ *************** *** 409,415 **** extern malloc_t safe_malloc P_((unsigned)); extern malloc_t safe_realloc P_((malloc_t,unsigned)); ! extern char *safe_strdup P_((CONST char *)); #ifdef DEBUG #define free(x) safe_free(x) --- 409,415 ---- extern malloc_t safe_malloc P_((unsigned)); extern malloc_t safe_realloc P_((malloc_t,unsigned)); ! extern char *safe_strdup P_((const char *)); #ifdef DEBUG #define free(x) safe_free(x) *************** *** 418,430 **** /* shiftlower.c */ ! extern char *shift_lower P_((CONST char *)); /* strfcpy.c */ ! extern char *strfcpy P_((char *, CONST char *, int)); ! extern char *strfcat P_((char *, CONST char *, int)); ! extern char *strnfcpy P_((char *dest, CONST char *src, int len, int size, int *produced)); --- 418,430 ---- /* shiftlower.c */ ! extern char *shift_lower P_((const char *)); /* strfcpy.c */ ! extern char *strfcpy P_((char *, const char *, int)); ! extern char *strfcat P_((char *, const char *, int)); ! extern char *strnfcpy P_((char *dest, const char *src, int len, int size, int *produced)); *************** *** 434,445 **** * - K E H */ ! extern int strincmp P_((CONST char *, CONST char *, int)); /* striparens.c */ ! extern char *strip_parens P_((CONST char *s)); ! extern char *get_parens P_((CONST char *s)); /* strstr.c */ --- 434,445 ---- * - K E H */ ! extern int strincmp P_((const char *, const char *, int)); /* striparens.c */ ! extern char *strip_parens P_((const char *s)); ! extern char *get_parens P_((const char *s)); /* strstr.c */ *************** *** 511,517 **** extern int mime_get_param P_((const char *name, char *value, const char *opts, int size)); extern void rfc822_reap_comments P_((char *, char *, int)); ! extern char * dequote_opt P_((CONST char *source, int len)); /* lib/charset.c */ --- 511,517 ---- extern int mime_get_param P_((const char *name, char *value, const char *opts, int size)); extern void rfc822_reap_comments P_((char *, char *, int)); ! extern char * dequote_opt P_((const char *source, int len)); /* lib/charset.c */ *************** *** 712,718 **** /* Set initial value */ extern void set_dt_estr P_((struct dt_estr_info *ptr, ! CONST char *const_val, char *def_env)); typedef struct dt_enumerate_info ENUMERATE; --- 712,718 ---- /* Set initial value */ extern void set_dt_estr P_((struct dt_estr_info *ptr, ! const char *const_val, char *def_env)); typedef struct dt_enumerate_info ENUMERATE; Index: elm2.4.ME+.123a-cvs/lib/cancel.c *** elm2.4.ME+.123/lib/cancel.c Wed Jul 5 20:21:50 2006 --- elm2.4.ME+.123a-cvs/lib/cancel.c Mon Jul 24 21:45:00 2006 *************** *** 1,7 **** ! static char rcsid[] = "@(#)$Id: cancel.c,v 1.5 2006/04/09 07:37:08 hurtta Exp $"; /****************************************************************************** ! * The Elm (ME+) Mail System - $Revision: 1.5 $ $State: Exp $ * * Author: Kari Hurtta *****************************************************************************/ --- 1,7 ---- ! static char rcsid[] = "@(#)$Id: cancel.c,v 1.6 2006/07/24 18:45:00 hurtta Exp $"; /****************************************************************************** ! * The Elm (ME+) Mail System - $Revision: 1.6 $ $State: Exp $ * * Author: Kari Hurtta *****************************************************************************/ *************** *** 232,238 **** } else { DPRINT(Debug,1,(&Debug,"failed to reset SIGINT handler\n")); } ! state_set = 1; #endif } --- 232,238 ---- } else { DPRINT(Debug,1,(&Debug,"failed to reset SIGINT handler\n")); } ! state_set = 0; #endif } Index: elm2.4.ME+.123a-cvs/lib/headers.c *** elm2.4.ME+.123/lib/headers.c Wed Jul 5 20:21:50 2006 --- elm2.4.ME+.123a-cvs/lib/headers.c Mon Jul 24 21:45:00 2006 *************** *** 1,7 **** ! static char rcsid[] = "@(#)$Id: headers.c,v 1.36 2006/04/20 19:36:19 hurtta Exp $"; /****************************************************************************** ! * The Elm (ME+) Mail System - $Revision: 1.36 $ $State: Exp $ * * Author: Kari Hurtta (was hurtta+elm@ozone.FMI.FI) *****************************************************************************/ --- 1,7 ---- ! static char rcsid[] = "@(#)$Id: headers.c,v 1.37 2006/07/24 18:45:00 hurtta Exp $"; /****************************************************************************** ! * The Elm (ME+) Mail System - $Revision: 1.37 $ $State: Exp $ * * Author: Kari Hurtta (was hurtta+elm@ozone.FMI.FI) *****************************************************************************/ *************** *** 598,604 **** { static struct header_scan_list * root = NULL; ! static struct header_scan_list * tmp; if (! root) { int i; --- 598,605 ---- { static struct header_scan_list * root = NULL; ! ! struct header_scan_list * tmp; if (! root) { int i; Index: elm2.4.ME+.123a-cvs/lib/mbox/localmbx.c *** elm2.4.ME+.123/lib/mbox/localmbx.c Wed Jul 5 20:21:50 2006 --- elm2.4.ME+.123a-cvs/lib/mbox/localmbx.c Fri Jul 14 13:29:04 2006 *************** *** 1,7 **** ! static char rcsid[] = "@(#)$Id: localmbx.c,v 1.9 2006/07/02 13:45:06 hurtta Exp $"; /****************************************************************************** ! * The Elm (ME+) Mail System - $Revision: 1.9 $ $State: Exp $ * * Author: Kari Hurtta (was hurtta+elm@ozone.FMI.FI) * or Kari Hurtta --- 1,7 ---- ! static char rcsid[] = "@(#)$Id: localmbx.c,v 1.10 2006/07/14 10:29:04 hurtta Exp $"; /****************************************************************************** ! * The Elm (ME+) Mail System - $Revision: 1.10 $ $State: Exp $ * * Author: Kari Hurtta (was hurtta+elm@ozone.FMI.FI) * or Kari Hurtta *************** *** 5091,5101 **** --- 5091,5112 ---- FILE * fh; int status_written = 0; + /* FIXME: + * + * This should probably use real_start_we_local() + * real_end_we_local() + * on savefolder.c + * + * there is too many similar routines + */ + DPRINT(Debug,11,(&Debug, "mbx_mark_keep_normal: folder=%p (%s)\n", folder,folder->cur_folder_sys)); if (keep) { + int ch; + fh = folder_to_fd(folder,entry->offset); if (!fh) return; *************** *** 5159,5165 **** count = 0; while (count < entry->content_length) { ! int ch = getc(fh); if (EOF == ch) { DPRINT(Debug,11,(&Debug, --- 5170,5176 ---- count = 0; while (count < entry->content_length) { ! ch = getc(fh); if (EOF == ch) { DPRINT(Debug,11,(&Debug, *************** *** 5177,5182 **** --- 5188,5224 ---- DPRINT(Debug,11,(&Debug, "mbx_mark_keep_normal: wrote %d bytes of body\n", count)); + + /* + * parse_body_routine() excludes ending empty line from + * content_length, so add empty line always to mail + */ + + if (ch != '\n') { + DPRINT(Debug,1,(&Debug, + "mbx_mark_keep_normal: Last character was not NL !!\n")); + if (EOF != putc('\n',keep_state_ptr->a.file.keep_file)) { + DPRINT(Debug,11,(&Debug, + "mbx_mark_keep_normal: Added extra NL\n")); + } + } + + #ifndef MMDF + + /* blank line to keep mailx happy *sigh* */ + if (fprintf(keep_state_ptr->a.file.keep_file, "\n") == EOF) { + DPRINT(Debug,5,(&Debug, + "mbx_mark_keep_normal: Failed to add second NL to end of mail\n")); + } else { + DPRINT(Debug,11,(&Debug, + "mbx_mark_keep_normal: Added NL for empty line.\n")); + } + + #else + /* FIXME --- What is correct? */ + + #endif + } } Index: elm2.4.ME+.123a-cvs/lib/mbox/savefolder.c *** elm2.4.ME+.123/lib/mbox/savefolder.c Wed Jul 5 20:21:50 2006 --- elm2.4.ME+.123a-cvs/lib/mbox/savefolder.c Fri Jul 14 13:29:04 2006 *************** *** 1,7 **** ! static char rcsid[] = "@(#)$Id: savefolder.c,v 1.8 2006/07/01 07:37:48 hurtta Exp $"; /****************************************************************************** ! * The Elm (ME+) Mail System - $Revision: 1.8 $ $State: Exp $ * * Author: Kari Hurtta (was hurtta+elm@ozone.FMI.FI) ***************************************************************************** --- 1,7 ---- ! static char rcsid[] = "@(#)$Id: savefolder.c,v 1.9 2006/07/14 10:29:04 hurtta Exp $"; /****************************************************************************** ! * The Elm (ME+) Mail System - $Revision: 1.9 $ $State: Exp $ * * Author: Kari Hurtta (was hurtta+elm@ozone.FMI.FI) ***************************************************************************** *************** *** 1960,1967 **** int i; long NEW_pos = END_pos - 2L; ! /* parse_body_routine() excludes endinf empty line from content_length, so add empty line always to mail */ buffer[0] = '\0'; --- 1960,1969 ---- int i; long NEW_pos = END_pos - 2L; ! /* parse_body_routine() excludes ending empty line from content_length, so add empty line always to mail + + see also mbx_mark_keep_normal() on localmbx.c */ buffer[0] = '\0'; Index: elm2.4.ME+.123a-cvs/src/messages/canceled_mail.c *** elm2.4.ME+.123/src/messages/canceled_mail.c Wed Jul 5 20:21:50 2006 --- elm2.4.ME+.123a-cvs/src/messages/canceled_mail.c Sun Jul 23 11:47:23 2006 *************** *** 1,7 **** ! static char rcsid[] = "@(#)$Id: canceled_mail.c,v 1.15 2006/05/22 19:17:14 hurtta Exp $"; /****************************************************************************** ! * The Elm (ME+) Mail System - $Revision: 1.15 $ $State: Exp $ * * Author: Kari Hurtta *****************************************************************************/ --- 1,7 ---- ! static char rcsid[] = "@(#)$Id: canceled_mail.c,v 1.16 2006/07/23 08:47:23 hurtta Exp $"; /****************************************************************************** ! * The Elm (ME+) Mail System - $Revision: 1.16 $ $State: Exp $ * * Author: Kari Hurtta *****************************************************************************/ *************** *** 1345,1352 **** ! current->REC.env_from[0]) { int x; CONST char * t = mailer_env_from_value(headers->env_from,&x); ! strfcpy(current->REC.env_from,t, ! sizeof (current->REC.env_from)); } /* Adds env_from, if not set */ --- 1345,1355 ---- ! current->REC.env_from[0]) { int x; CONST char * t = mailer_env_from_value(headers->env_from,&x); ! ! /* Assurance */ ! if (t) ! strfcpy(current->REC.env_from,t, ! sizeof (current->REC.env_from)); } /* Adds env_from, if not set */ Index: elm2.4.ME+.123a-cvs/src/url/url.c *** elm2.4.ME+.123/src/url/url.c Wed Jul 5 20:21:50 2006 --- elm2.4.ME+.123a-cvs/src/url/url.c Mon Jul 24 21:45:00 2006 *************** *** 1,7 **** ! static char rcsid[] = "@(#)$Id: url.c,v 1.12 2006/07/01 07:37:48 hurtta Exp $"; /****************************************************************************** ! * The Elm (ME+) Mail System - $Revision: 1.12 $ $State: Exp $ * * Author: Kari Hurtta * or Kari Hurtta --- 1,7 ---- ! static char rcsid[] = "@(#)$Id: url.c,v 1.13 2006/07/24 18:45:00 hurtta Exp $"; /****************************************************************************** ! * The Elm (ME+) Mail System - $Revision: 1.13 $ $State: Exp $ * * Author: Kari Hurtta * or Kari Hurtta *************** *** 919,925 **** goto failure; } else { - no_path: /* No path */ if (0 != (sch->handler->flag & URLFLAG_path)) { --- 919,924 ---- Index: elm2.4.ME+.123a-cvs/utils/elmbindata.c *** elm2.4.ME+.123/utils/elmbindata.c Wed Jul 5 20:21:50 2006 --- elm2.4.ME+.123a-cvs/utils/elmbindata.c Thu Jul 27 18:06:10 2006 *************** *** 1,7 **** ! static char rcsid[] = "@(#)$Id: elmbindata.c,v 1.9 2006/04/09 07:37:30 hurtta Exp $"; /****************************************************************************** ! * The Elm (ME+) Mail System - $Revision: 1.9 $ $State: Exp $ * * Author: Kari Hurtta (was hurtta+elm@ozone.FMI.FI) *****************************************************************************/ --- 1,7 ---- ! static char rcsid[] = "@(#)$Id: elmbindata.c,v 1.10 2006/07/27 15:06:10 hurtta Exp $"; /****************************************************************************** ! * The Elm (ME+) Mail System - $Revision: 1.10 $ $State: Exp $ * * Author: Kari Hurtta (was hurtta+elm@ozone.FMI.FI) *****************************************************************************/ *************** *** 61,66 **** --- 61,74 ---- break; case 'I': target_file = bindata_path; + + if (0 == strcmp(bindata_path,"none")) { + /* This is more like debug option */ + fprintf(stderr,"%s: bindata = %s\n", + program_name,unidata_path); + target_file = NULL; + } + break; case 'S': copydirs = safe_realloc(copydirs,(copydir_count+1) * sizeof (*copydirs)); *************** *** 154,159 **** --- 162,178 ---- if (target_file && bindata) { if (!write_bindata(bindata,target_file)) exit(1); + + if (global && bindata_path && 0 == strcmp(bindata_path,target_file)) { + if (0 != chmod(target_file,0644)) { + int errcode = errno; + + fprintf(stderr,"%s: chmod %s: %s\n", + program_name, target_file, error_description(errcode)); + err = 1; + } + } + log_config(target_file); } Index: elm2.4.ME+.123a-cvs/utils/elmunidata.c *** elm2.4.ME+.123/utils/elmunidata.c Wed Jul 5 20:21:50 2006 --- elm2.4.ME+.123a-cvs/utils/elmunidata.c Thu Jul 27 18:06:10 2006 *************** *** 1,7 **** ! static char rcsid[] = "@(#)$Id: elmunidata.c,v 1.22 2006/04/09 07:37:30 hurtta Exp $"; /****************************************************************************** ! * The Elm (ME+) Mail System - $Revision: 1.22 $ $State: Exp $ * * Author: Kari Hurtta (was hurtta+elm@ozone.FMI.FI) *****************************************************************************/ --- 1,7 ---- ! static char rcsid[] = "@(#)$Id: elmunidata.c,v 1.23 2006/07/27 15:06:10 hurtta Exp $"; /****************************************************************************** ! * The Elm (ME+) Mail System - $Revision: 1.23 $ $State: Exp $ * * Author: Kari Hurtta (was hurtta+elm@ozone.FMI.FI) *****************************************************************************/ *************** *** 53,58 **** --- 53,66 ---- break; case 'I': target_file = unidata_path; + + if (0 == strcmp(unidata_path,"none")) { + /* This is more like debug option */ + fprintf(stderr,"%s: unidata = %s\n", + program_name,unidata_path); + target_file = NULL; + } + break; case 'l': logfile = fopen(optarg,"w"); *************** *** 141,146 **** --- 149,165 ---- if (target_file && unidata) { if (!write_unidata(unidata,target_file)) exit(1); + + if (unidata_path && 0 == strcmp(unidata_path,target_file)) { + if (0 != chmod(target_file,0644)) { + int errcode = errno; + + fprintf(stderr,"%s: chmod %s: %s\n", + program_name, target_file, error_description(errcode)); + err = 1; + } + } + log_config(target_file); }