--- parser3/src/classes/mail.C 2003/03/26 13:46:57 1.88.2.16.2.14 +++ parser3/src/classes/mail.C 2003/09/25 09:15:02 1.90 @@ -5,7 +5,7 @@ Author: Alexandr Petrosian (http://paf.design.ru) */ -static const char* IDENT_MAIL_C="$Date: 2003/03/26 13:46:57 $"; +static const char* IDENT_MAIL_C="$Date: 2003/09/25 09:15:02 $"; #include "pa_config_includes.h" #include "pa_vmethod_frame.h" @@ -80,7 +80,7 @@ static void sendmail(Request& r, Value* server_port; // $MAIN:MAIL.SMTP[mail.yourdomain.ru[:port]] if(vmail_conf && - (server_port=vmail_conf->get_hash()->get(StringBody("SMTP")))) { + (server_port=vmail_conf->get_hash()->get(String::Body("SMTP")))) { char* server=server_port->as_string().cstrm(); const char* port=rsplit(server, ':'); if(!port) @@ -115,10 +115,11 @@ static void sendmail(Request& r, #ifdef PA_FORCED_SENDMAIL sendmail_command=new String(PA_FORCED_SENDMAIL); #else - sendmail_command=new String("/usr/sbin/sendmail"); - if(!file_executable(test)) - sendmail_command=new String("/usr/lib/sendmail"); - *sendmail_command<<" -t -i -f postmaster"; + String* test=new String("/usr/sbin/sendmail"); + if(!file_executable(*test)) + test=new String("/usr/lib/sendmail"); + *test<<" -t -i -f postmaster"; + sendmail_command=test; #endif } @@ -179,8 +180,8 @@ static void sendmail(Request& r, // methods -static void _send(Request& r, MethodParams* params) { - Value& vhash=params->as_no_junction(0, "message must not be code"); +static void _send(Request& r, MethodParams& params) { + Value& vhash=params.as_no_junction(0, "message must not be code"); HashStringValue* hash=vhash.get_hash(); if(!hash) throw Exception("parser.runtime",