1
0
Fork 0
mirror of https://github.com/albfan/miraclecast.git synced 2025-03-09 23:38:56 +00:00

miracle-dispd: put back gstreamer

in this version, the pipeline can be stopped properly, but the gst &
glib allocated memory can't be release cleanly (which won't
accumulate)

Change-Id: I242b106158db647070e7852b84f6f90b6bbd96f4
This commit is contained in:
Derek Dai 2017-04-13 10:55:50 +08:00
parent e117704d4e
commit e0a3b62e6b
3 changed files with 265 additions and 257 deletions

View file

@ -23,6 +23,7 @@
#include <stdlib.h>
#include <string.h>
#include <time.h>
#include <gst/gst.h>
#include <systemd/sd-event.h>
#include <systemd/sd-daemon.h>
#include "ctl.h"
@ -451,6 +452,8 @@ int main(int argc, char **argv)
setlocale(LC_ALL, "");
setlocale(LC_TIME, "en_US.UTF-8");
gst_init(&argc, &argv);
if(getenv("LOG_LEVEL")) {
log_max_sev = log_parse_arg(getenv("LOG_LEVEL"));
}
@ -518,6 +521,7 @@ disable_watchdog:
unref_event:
sd_event_unref(event);
end:
gst_deinit();
return r < 0 ? EXIT_FAILURE : EXIT_SUCCESS;
}