Use glib function to open file (fix one of security issues)
Signed-off-by: Jaeyun Jung <jy1210.jung@samsung.com>
#include <gst/gstinfo.h>
#include <gst/gst.h>
#include <glib.h>
+#include <glib/gstdio.h>
#include <string.h>
#include <endian.h>
#include <fcntl.h>
GError *error = NULL;
filename = g_build_filename (base_dir, file, NULL);
- fd = fopen (filename, "w");
+ fd = g_fopen (filename, "w");
if (fd == NULL) {
GST_ERROR_OBJECT (self, "Unable to open file to write %s.\n", filename);
goto error_free_filename;