⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 smtpport.h

📁 在ARM7和UC/OSII的平台上实现了GPS自动报站的功能,涉及GPS模块LEA_4S的驱动,位置速寻算法,语音芯片ISD4004的录放音驱动,LED页面管理等等.从启动代码到操作系统的移植以及到业
💻 H
字号:
/* smtpport.h

   Copyright 1997 by InterNice Technologies Inc. All rights reserved.
   Copyright 1996 by NetPort Software. All rights reserved.

   Email alerter port definitions.

*/

#ifndef _SMTPPORT_H
#define _SMTPPORT_H 1

#include "ipport.h"    /* NetPort IP stack defines */
#include "libport.h"

#include "dns.h"       /* InterNiche DNS API */

#include "tcpapp.h"

/* Per-port tunable SMTP parameters: */
#define  SMTP_HEADER_SIZE	256	/* including header data */
#define  MAX_SMTP_RCPTS		4     /* max number of recipients */
#define  MAX_RCPT_LEN      48    /* max length of recipient name */

/* malloc and free for queued alert message text mgt structures */
#define  alertmsg_alloc()	(alertmsg_p)npalloc(sizeof (struct alertmessage))
#define  alertmsg_free(m)	npfree((char *)m)

int   smtpalert_task(void);   /* entry point for thread or Superloop */
int   smtp_init(void);


/* SignalEmailTask is a per-port routine which is called whenever
the Mail Que changes between NULL and non-NULL. It should ensure that
the smtpalert_task() gets called peridicly while the que in non-NULL.

Since SUPERLOOP always polls, default to noop here:
*/
#ifndef  SignalEmailTask      /* Allow override from ipport,h_h */
#define  SignalEmailTask();   /* Superloop Default to NO-OP */
#endif

/* message send result counters */
extern unsigned smtp_esocket;    /* socket error counter */
extern unsigned smtp_badcode;    /* smtp reply code of 501, 503, etc*/
extern unsigned smtp_esmtp;
extern unsigned smtp_oksend;     /* emails which went out OK */

extern int smtp_tcpconnect(WP_SOCKTYPE *,ip_addr, unsigned port);

#define SYS_EWOULDBLOCK EWOULDBLOCK

/* non-blocking connect timeout, in seconds */
#define EMCONN_TMO 25

/* SMTP Client related non-volatile parameters. Please see nvparms.h
 * and nvparms.c regarding the usage of the following structure.
 */
#ifdef INCLUDE_NVPARMS
struct smtp_nvparam
{
   /* SMTP (email alerter) section */
   ip_addr  mserver; /* SMTP mail server's IP address */
   char  rcpt[MAX_NVSTRING];  /* slot for 1 recipient */
};

extern struct smtp_nvparam smtp_nvparms;
#endif /* INCLUDE_NVPARMS */

#endif /* _SMTPPORT_H */

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -