mirror of
https://github.com/zotanmew/nginx-rtmp-module.git
synced 2024-06-14 02:55:06 +02:00
fixed compilation (dup result)
This commit is contained in:
parent
01d3b8857c
commit
ce7ae837b3
|
@ -260,15 +260,9 @@ ngx_rtmp_enotify_exec(ngx_rtmp_session_t *s, ngx_rtmp_enotify_conf_t *ec)
|
||||||
/* child */
|
/* child */
|
||||||
fd = open("/dev/null", O_RDWR);
|
fd = open("/dev/null", O_RDWR);
|
||||||
|
|
||||||
if (fd != -1) {
|
dup2(fd, STDIN_FILENO);
|
||||||
close(0);
|
dup2(fd, STDOUT_FILENO);
|
||||||
close(1);
|
dup2(fd, STDERR_FILENO);
|
||||||
close(2);
|
|
||||||
|
|
||||||
dup(fd);
|
|
||||||
dup(fd);
|
|
||||||
dup(fd);
|
|
||||||
}
|
|
||||||
|
|
||||||
args = ngx_palloc(s->connection->pool,
|
args = ngx_palloc(s->connection->pool,
|
||||||
(ec->args.nelts + 2) * sizeof(char *));
|
(ec->args.nelts + 2) * sizeof(char *));
|
||||||
|
|
|
@ -346,15 +346,9 @@ ngx_rtmp_exec_run(ngx_rtmp_session_t *s, size_t n)
|
||||||
/* child */
|
/* child */
|
||||||
fd = open("/dev/null", O_RDWR);
|
fd = open("/dev/null", O_RDWR);
|
||||||
|
|
||||||
if (fd != -1) {
|
dup2(fd, STDIN_FILENO);
|
||||||
close(0);
|
dup2(fd, STDOUT_FILENO);
|
||||||
close(1);
|
dup2(fd, STDERR_FILENO);
|
||||||
close(2);
|
|
||||||
|
|
||||||
dup(fd);
|
|
||||||
dup(fd);
|
|
||||||
dup(fd);
|
|
||||||
}
|
|
||||||
|
|
||||||
args = ngx_palloc(s->connection->pool,
|
args = ngx_palloc(s->connection->pool,
|
||||||
(ec->args.nelts + 2) * sizeof(char *));
|
(ec->args.nelts + 2) * sizeof(char *));
|
||||||
|
|
Loading…
Reference in a new issue