diff --git a/meson.build b/meson.build index 26841d2..5241d05 100644 --- a/meson.build +++ b/meson.build @@ -1,5 +1,5 @@ project('amazon-s3-gst-plugin', 'c', 'cpp', - version : '0.2.1-lldc.8', + version : '0.2.1-lldc.9', default_options : [ 'warning_level=2', 'buildtype=debugoptimized' ]) @@ -19,7 +19,6 @@ endif apiversion = '1.0' -glib_dep = dependency('glib-2.0') gst_dep = dependency('gstreamer-1.0', version : gst_req, fallback : ['gstreamer', 'gst_dep']) gst_base_dep = dependency('gstreamer-base-1.0', version : gst_req, diff --git a/src/gsts3sink.c b/src/gsts3sink.c index 19c138f..9291052 100644 --- a/src/gsts3sink.c +++ b/src/gsts3sink.c @@ -306,7 +306,6 @@ static void gst_s3_sink_init (GstS3Sink * s3sink) { s3sink->config = GST_S3_UPLOADER_CONFIG_INIT; - s3sink->config.credentials = gst_aws_credentials_new_default (); s3sink->uploader = NULL; s3sink->downloader = NULL; s3sink->is_started = FALSE; @@ -328,7 +327,8 @@ gst_s3_sink_release_config (GstS3UploaderConfig * config) g_free (config->content_type); g_free (config->ca_file); g_free (config->aws_sdk_endpoint); - gst_aws_credentials_free (config->credentials); + if (config->credentials) + gst_aws_credentials_free (config->credentials); *config = GST_S3_UPLOADER_CONFIG_INIT; } @@ -533,6 +533,9 @@ gst_s3_sink_start (GstBaseSink * basesink) || gst_s3_sink_is_null_or_empty (sink->config.key))) goto no_destination; + if (!sink->config.credentials) + sink->config.credentials = gst_aws_credentials_new_default (); + if (sink->uploader == NULL) { sink->uploader = GST_S3_SINK_GET_CLASS((gpointer*) sink)->uploader_new (&sink->config); } diff --git a/tests/check/meson.build b/tests/check/meson.build index f9395b7..4aa7412 100644 --- a/tests/check/meson.build +++ b/tests/check/meson.build @@ -17,7 +17,7 @@ foreach test_file : element_tests ) env = environment() - env.set('GST_PLUGIN_PATH_1_0', meson.build_root()) + env.set('GST_PLUGIN_PATH_1_0', meson.project_build_root()) env.set('GST_DEBUG', 'check:TRACE,s3sink:TRACE') test(test_name, exe, timeout: 3 * 60, env: env) endforeach