diff options
-rw-r--r-- | smtp.c | 14 | ||||
-rw-r--r-- | socket.c | 8 |
2 files changed, 11 insertions, 11 deletions
@@ -23,7 +23,7 @@ int SMTP_helo(FILE *sockfp,char *host) { int ok; - SockPrintf(fileno(sockfp),"HELO %s\r\n", host); + SockPrintf(sockfp,"HELO %s\r\n", host); if (outlevel == O_VERBOSE) fprintf(stderr, "SMTP> HELO %s\n", host); ok = SMTP_ok(sockfp,NULL); @@ -35,7 +35,7 @@ int SMTP_from(FILE *sockfp, char *from) { int ok; - SockPrintf(fileno(sockfp),"MAIL FROM:<%s>\r\n", from); + SockPrintf(sockfp,"MAIL FROM:<%s>\r\n", from); if (outlevel == O_VERBOSE) fprintf(stderr, "SMTP> MAIL FROM:<%s>\n", from); ok = SMTP_ok(sockfp,NULL); @@ -47,7 +47,7 @@ int SMTP_rcpt(FILE *sockfp, char *to) { int ok; - SockPrintf(fileno(sockfp),"RCPT TO:<%s>\r\n", to); + SockPrintf(sockfp,"RCPT TO:<%s>\r\n", to); if (outlevel == O_VERBOSE) fprintf(stderr, "SMTP> RCPT TO:<%s>\n", to); ok = SMTP_ok(sockfp,NULL); @@ -59,7 +59,7 @@ int SMTP_data(FILE *sockfp) { int ok; - SockPrintf(fileno(sockfp),"DATA\r\n"); + SockPrintf(sockfp,"DATA\r\n"); if (outlevel == O_VERBOSE) fprintf(stderr, "SMTP> DATA\n"); ok = SMTP_ok(sockfp,NULL); @@ -71,7 +71,7 @@ int SMTP_quit(FILE *sockfp) { int ok; - SockPrintf(fileno(sockfp),"QUIT\r\n"); + SockPrintf(sockfp,"QUIT\r\n"); if (outlevel == O_VERBOSE) fprintf(stderr, "SMTP> QUIT\n"); ok = SMTP_ok(sockfp,NULL); @@ -83,7 +83,7 @@ int SMTP_eom(FILE *sockfp) { int ok; - SockPrintf(fileno(sockfp),".\r\n"); + SockPrintf(sockfp,".\r\n"); if (outlevel == O_VERBOSE) fprintf(stderr, "SMTP>. (EOM)\n"); ok = SMTP_ok(sockfp,NULL); @@ -93,7 +93,7 @@ int SMTP_eom(FILE *sockfp) void SMTP_rset(FILE *sockfp) /* send a "RSET" message to the SMTP listener */ { - SockPrintf(fileno(sockfp),"RSET\r\n"); + SockPrintf(sockfp,"RSET\r\n"); if (outlevel == O_VERBOSE) fprintf(stderr, "SMTP> RSET\n"); } @@ -195,11 +195,11 @@ FILE *sockfp; } #if defined(HAVE_STDARG_H) -int SockPrintf(int socket, char* format, ...) +int SockPrintf(FILE *sockfp, char* format, ...) { #else -int SockPrintf(socket,format,va_alist) -int socket; +int SockPrintf(sockfp,format,va_alist) +FILE *sockfp; char *format; va_dcl { #endif @@ -214,7 +214,7 @@ va_dcl { #endif vsprintf(buf, format, ap); va_end(ap); - return SockWrite(socket, buf, strlen(buf)); + return SockWrite(fileno(sockfp), buf, strlen(buf)); } |