- Timestamp:
- Feb 18, 2009, 7:30:38 PM (16 years ago)
- Location:
- trunk
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/include/sh_mail.h
r214 r216 54 54 int sh_mail_pushstack (int severity, const char * msg, const char * alias); 55 55 56 /* Set the port to use (default 25) 57 */ 58 int sh_mail_set_port (const char * str); 59 56 60 /* set sender of mail 57 61 */ 58 62 int sh_mail_set_sender (const char *str); 59 63 60 int sh_mail_add_or (const char * str);61 int sh_mail_add_and (const char * str);62 int sh_mail_add_not (const char * str);63 64 64 #endif -
trunk/src/sh_mail.c
r215 r216 916 916 } 917 917 918 static int sh_mail_port = IPPORT_SMTP; 919 920 int sh_mail_set_port (const char * str) 921 { 922 int i = atoi (str); 923 924 SL_ENTER(_("sh_mail_set_port")); 925 926 if (i >= 0 && i < 65535) 927 { 928 sh_mail_port = i; 929 } 930 else 931 { 932 sh_mail_port = IPPORT_SMTP; 933 SL_RETURN ((-1), _("sh_mail_set_port")); 934 } 935 936 SL_RETURN( (0), _("sh_mail_set_port")); 937 } 918 938 919 939 /************************* … … 1017 1037 TPT((0, FIL__, __LINE__, _("msg=<user %s machine %s>\n"), 1018 1038 ma_user, ma_machine)); 1019 fd = connect_port (ma_machine, IPPORT_SMTP,1039 fd = connect_port (ma_machine, sh_mail_port, 1020 1040 error_call, &error_num, error_msg, 256); 1021 1041 } … … 1040 1060 _("msg=<user %s mx %s pref %d>\n"), 1041 1061 ma_user, ma_machine, result[i].pref)); 1042 fd = connect_port (ma_machine, IPPORT_SMTP,1062 fd = connect_port (ma_machine, sh_mail_port, 1043 1063 error_call, &error_num, error_msg, 256); 1044 1064 if (fd >= 0) -
trunk/src/sh_readconf.c
r215 r216 1101 1101 { N_("setmailrelay"), SH_SECTION_MAIL, SH_SECTION_MISC, 1102 1102 sh_mail_set_relay }, 1103 { N_("setmailport"), SH_SECTION_MAIL, SH_SECTION_MISC, 1104 sh_mail_set_port }, 1103 1105 { N_("mailsingle"), SH_SECTION_MAIL, SH_SECTION_MISC, 1104 1106 sh_mail_setFlag },
Note:
See TracChangeset
for help on using the changeset viewer.