NULL,
&err);
else {
- g_autofree GDBusProxy *proxy = NULL;
+ g_autoptr(GDBusProxy) proxy = NULL;
proxy = g_dbus_proxy_new_for_bus_sync(G_BUS_TYPE_SYSTEM,
G_DBUS_PROXY_FLAGS_NONE,
}
int systemd_subscribe(GDBusConnection *connection, char **err_msg) {
- g_autofree GVariant *reply = NULL;
- g_autofree GError *error = NULL;
+ g_autoptr(GVariant) reply = NULL;
+ g_autoptr(GError) error = NULL;
int r;
r = systemd_call_sync(connection,
}
int systemd_unsubscribe(GDBusConnection *connection, char **err_msg) {
- g_autofree GVariant *reply = NULL;
- g_autofree GError *error = NULL;
+ g_autoptr(GVariant) reply = NULL;
+ g_autoptr(GError) error = NULL;
int r;
r = systemd_call_sync(connection,
char **unit,
char **err_msg) {
- g_autofree GVariant *reply = NULL;
- g_autofree GError *error = NULL;
+ g_autoptr(GVariant) reply = NULL;
+ g_autoptr(GError) error = NULL;
char *obj = NULL;
int r;
char **job,
char **err_msg) {
- g_autofree GVariant *reply = NULL;
- g_autofree GError *error = NULL;
+ g_autoptr(GVariant) reply = NULL;
+ g_autoptr(GError) error = NULL;
char *obj = NULL;
int r;
GVariant **variant,
char **err_msg) {
- g_autofree GError *error = NULL;
+ g_autoptr(GError) error = NULL;
int r;
assert(name);
value* result, \
char** err_msg) { \
\
- g_autofree GVariant *var = NULL, *inner = NULL; \
+ g_autoptr(GVariant) var = NULL, inner = NULL; \
int r; \
\
assert(target); \
static int systemd_parse_list_units_result(GVariant *result, GList **unit_list) {
char *name, *description, *load_state, *active_state, *sub_state;
char *followed, *obj_path, *job_type, *job_obj_path;
- g_autofree GVariantIter *iter;
+ g_autoptr(GVariantIter) iter;
unsigned int job_id;
GList *list = NULL;
int r;
}
int systemd_get_units_list(GDBusConnection *conn, GList **unit_list, char **err_msg) {
- g_autofree GVariant *reply = NULL;
- g_autofree GError *error = NULL;
+ g_autoptr(GVariant) reply = NULL;
+ g_autoptr(GError) error = NULL;
int r;
assert(unit_list);
}
static int systemd_parse_list_unit_files_result(GVariant *result, GList **unit_files_list) {
- g_autofree GVariantIter *iter;
+ g_autoptr(GVariantIter) iter;
GList *list = NULL;
char *name, *status;
int r;
}
int systemd_get_unit_files_list(GDBusConnection *conn, GList **unit_files_list, char **err_msg) {
- g_autofree GVariant *reply = NULL;
- g_autofree GError *error = NULL;
+ g_autoptr(GVariant) reply = NULL;
+ g_autoptr(GError) error = NULL;
int r;
assert(conn);