Make ffserver show each launched commandline just before to launch
them rather than print them when parsing the configuration file. This way those commandlines are not showed anymore in no-launch mode. Originally committed as revision 13950 to svn://svn.ffmpeg.org/ffmpeg/trunk
This commit is contained in:
parent
0e1d6a4ca7
commit
40444a59c1
35
ffserver.c
35
ffserver.c
@ -407,6 +407,23 @@ static void start_children(FFStream *feed)
|
|||||||
char *slash;
|
char *slash;
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
|
av_strlcpy(pathname, my_program_name, sizeof(pathname));
|
||||||
|
|
||||||
|
slash = strrchr(pathname, '/');
|
||||||
|
if (!slash)
|
||||||
|
slash = pathname;
|
||||||
|
else
|
||||||
|
slash++;
|
||||||
|
strcpy(slash, "ffmpeg");
|
||||||
|
|
||||||
|
if (ffserver_debug) {
|
||||||
|
fprintf(stdout, "Launch commandline: ");
|
||||||
|
fprintf(stdout, "%s ", pathname);
|
||||||
|
for (i = 1; feed->child_argv[i] && feed->child_argv[i][0]; i++)
|
||||||
|
fprintf(stdout, "%s ", feed->child_argv[i]);
|
||||||
|
fprintf(stdout, "\n");
|
||||||
|
}
|
||||||
|
|
||||||
for (i = 3; i < 256; i++)
|
for (i = 3; i < 256; i++)
|
||||||
close(i);
|
close(i);
|
||||||
|
|
||||||
@ -420,15 +437,6 @@ static void start_children(FFStream *feed)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
av_strlcpy(pathname, my_program_name, sizeof(pathname));
|
|
||||||
|
|
||||||
slash = strrchr(pathname, '/');
|
|
||||||
if (!slash)
|
|
||||||
slash = pathname;
|
|
||||||
else
|
|
||||||
slash++;
|
|
||||||
strcpy(slash, "ffmpeg");
|
|
||||||
|
|
||||||
/* This is needed to make relative pathnames work */
|
/* This is needed to make relative pathnames work */
|
||||||
chdir(my_program_dir);
|
chdir(my_program_dir);
|
||||||
|
|
||||||
@ -3883,15 +3891,6 @@ static int parse_ffconfig(const char *filename)
|
|||||||
(my_http_addr.sin_addr.s_addr == INADDR_ANY) ? "127.0.0.1" :
|
(my_http_addr.sin_addr.s_addr == INADDR_ANY) ? "127.0.0.1" :
|
||||||
inet_ntoa(my_http_addr.sin_addr),
|
inet_ntoa(my_http_addr.sin_addr),
|
||||||
ntohs(my_http_addr.sin_port), feed->filename);
|
ntohs(my_http_addr.sin_port), feed->filename);
|
||||||
|
|
||||||
if (ffserver_debug)
|
|
||||||
{
|
|
||||||
int j;
|
|
||||||
fprintf(stdout, "Launch commandline: ");
|
|
||||||
for (j = 0; j <= i; j++)
|
|
||||||
fprintf(stdout, "%s ", feed->child_argv[j]);
|
|
||||||
fprintf(stdout, "\n");
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
} else if (!strcasecmp(cmd, "ReadOnlyFile")) {
|
} else if (!strcasecmp(cmd, "ReadOnlyFile")) {
|
||||||
if (feed) {
|
if (feed) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user