提交 8dc23d38 authored 作者: Michael Jerris's avatar Michael Jerris

dos2unix

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@5668 d0543943-73ff-0310-b7d9-9358b9ac24b2
上级 b2c2465a
......@@ -966,16 +966,16 @@ static int preprocess(const char *file, int write_fd, int rlevel)
}
}
if ((cmd = strstr(bp, "<!--#"))) {
if(write(write_fd, bp, (unsigned) (cmd - bp)) != (cmd - bp)) {
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Short write!\n");
}
if ((cmd = strstr(bp, "<!--#"))) {
if(write(write_fd, bp, (unsigned) (cmd - bp)) != (cmd - bp)) {
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Short write!\n");
}
if ((e = strstr(cmd, "-->"))) {
*e = '\0';
e += 3;
if(write(write_fd, e, (unsigned) strlen(e)) != (int) strlen(e)) {
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Short write!\n");
}
e += 3;
if(write(write_fd, e, (unsigned) strlen(e)) != (int) strlen(e)) {
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Short write!\n");
}
} else {
ml++;
}
......@@ -1031,11 +1031,11 @@ static int preprocess(const char *file, int write_fd, int rlevel)
continue;
}
if(write(write_fd, bp, (unsigned) cur) != (int) cur) {
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Short write!\n");
}
if(write(write_fd, bp, (unsigned) cur) != (int) cur) {
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Short write!\n");
}
}
close(read_fd);
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论