/* subprocess.c generated by valac 0.56.19, the Vala compiler
 * generated from subprocess.vala, do not modify */

#include <gio/gio.h>
#include <stdlib.h>
#include <string.h>
#include <glib.h>

#if !defined(VALA_STRICT_C)
#if !defined(__clang__) && defined(__GNUC__) && (__GNUC__ >= 14)
#pragma GCC diagnostic warning "-Wincompatible-pointer-types"
#elif defined(__clang__) && (__clang_major__ >= 16)
#pragma clang diagnostic ignored "-Wincompatible-function-pointer-types"
#pragma clang diagnostic ignored "-Wincompatible-pointer-types"
#endif
#endif
#if !defined(VALA_EXTERN)
#if defined(_MSC_VER)
#define VALA_EXTERN __declspec(dllexport) extern
#elif __GNUC__ >= 4
#define VALA_EXTERN __attribute__((visibility("default"))) extern
#else
#define VALA_EXTERN extern
#endif
#endif

#define _g_object_unref0(var) ((var == NULL) ? NULL : (var = (g_object_unref (var), NULL)))

VALA_EXTERN GSubprocess* dc_subprocess_util_spawnv (GSubprocessLauncher* launcher,
                                        gchar** argv,
                                        gint argv_length1,
                                        GError** error);

GSubprocess*
dc_subprocess_util_spawnv (GSubprocessLauncher* launcher,
                           gchar** argv,
                           gint argv_length1,
                           GError** error)
{
	GSubprocess* _tmp0_ = NULL;
	GSubprocess* _tmp1_;
	GSubprocess* _tmp2_;
	GError* _inner_error0_ = NULL;
	GSubprocess* result;
	g_return_val_if_fail (launcher != NULL, NULL);
	_tmp1_ = g_subprocess_launcher_spawnv (launcher, (const gchar * const *) argv, &_inner_error0_);
	_tmp0_ = _tmp1_;
	if (G_UNLIKELY (_inner_error0_ != NULL)) {
		g_propagate_error (error, _inner_error0_);
		return NULL;
	}
	_tmp2_ = _tmp0_;
	_tmp0_ = NULL;
	result = _tmp2_;
	_g_object_unref0 (_tmp0_);
	return result;
}

