Commit 37d5d89b authored by Jean-Paul Saman's avatar Jean-Paul Saman

dvbinfo: extra check

parent 46922a50
...@@ -442,6 +442,11 @@ int main(int argc, char **pp_argv) ...@@ -442,6 +442,11 @@ int main(int argc, char **pp_argv)
usage(); usage();
param = params_init(); param = params_init();
if (param == NULL)
{
printf("dvbinfo: out of memory\n");
exit(EXIT_FAILURE);
}
capture.params = param; capture.params = param;
capture.fifo = fifo_new(); capture.fifo = fifo_new();
capture.empty = fifo_new(); capture.empty = fifo_new();
...@@ -706,6 +711,7 @@ int main(int argc, char **pp_argv) ...@@ -706,6 +711,7 @@ int main(int argc, char **pp_argv)
closelog(); closelog();
#endif #endif
params_free(param); params_free(param);
param = NULL;
if (err < 0) if (err < 0)
exit(EXIT_FAILURE); exit(EXIT_FAILURE);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment