基于socket的简单发送短信程序

时间:2016-07-07 10:18:39
【文件属性】:
文件名称:基于socket的简单发送短信程序
文件大小:6KB
文件格式:RAR
更新时间:2016-07-07 10:18:39
socket 基础技术 基于socket的一个读取文件内容,发送短信的小功能 包括日志级别设置、功能选择等小结构,闲来无事可以看看。 int main(int argc, char **argv) { DIR * dir; struct dirent * ptr; int i; char filename[100]; int ch; int iPid; opterr = 0; while((ch = getopt(argc,argv,"d:f:L:l:h:p:"))!= -1){ switch(ch){ case 'd': workdir = (char *)strdup(optarg); break; case 'f': srcdir = (char *)strdup(optarg); break; case 'L': logdir = (char *)strdup(optarg); break; case 'l': loglevel = atoi(optarg); if((loglevelL_ERROR)){ printf("日志级别设置错误\n"); return -1; } break; case 'h': addr = (char *)strdup(optarg); break; case 'p': port = atoi(optarg); break; default: usage(); return -1; } }
【文件预览】:
test
----wsms.h(466B)
----util.c(824B)
----Makefile(338B)
----wsms.c(8KB)
----transmit.c(5KB)
----log.c(1KB)

网友评论