summaryrefslogtreecommitdiff
path: root/ffserver.c
diff options
context:
space:
mode:
authorReynaldo H. Verdejo Pinochet <reynaldo@osg.samsung.com>2015-12-14 23:28:03 -0800
committerReynaldo H. Verdejo Pinochet <reynaldo@osg.samsung.com>2015-12-15 10:04:59 -0800
commit0bdf84b6b0527d30970c5fa555c7bc00a852a3cc (patch)
tree30b59fe4d8e5c77f470175dde1c480ebdad4925a /ffserver.c
parentdadb95142bd4e8c2b831824e666bbc8b5888f501 (diff)
downloadffmpeg-0bdf84b6b0527d30970c5fa555c7bc00a852a3cc.tar.gz
ffserver: explicitly use time_t for uptime calc
Signed-off-by: Reynaldo H. Verdejo Pinochet <reynaldo@osg.samsung.com>
Diffstat (limited to 'ffserver.c')
-rw-r--r--ffserver.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/ffserver.c b/ffserver.c
index fcee8742d1..129f9fd462 100644
--- a/ffserver.c
+++ b/ffserver.c
@@ -3807,7 +3807,8 @@ static void compute_bandwidth(void)
static void handle_child_exit(int sig)
{
pid_t pid;
- int status, uptime;
+ int status;
+ time_t uptime;
while ((pid = waitpid(-1, &status, WNOHANG)) > 0) {
FFServerStream *feed;
@@ -3819,7 +3820,8 @@ static void handle_child_exit(int sig)
uptime = time(0) - feed->pid_start;
feed->pid = 0;
fprintf(stderr,
- "%s: Pid %"PRId64" exited with status %d after %d seconds\n",
+ "%s: Pid %"PRId64" exited with status %d after %"PRId64" "
+ "seconds\n",
feed->filename, (int64_t) pid, status, uptime);
if (uptime < 30)