提交 9665fbb2 编写于 作者: J Ján Tomko

Delete virObjectAutoUnref

Signed-off-by: NJán Tomko <jtomko@redhat.com>
Reviewed-by: NMichal Privoznik <mprivozn@redhat.com>
上级 2b390b97
......@@ -2636,7 +2636,6 @@ virClassForObjectRWLockable;
virClassIsDerivedFrom;
virClassName;
virClassNew;
virObjectAutoUnref;
virObjectFreeCallback;
virObjectFreeHashData;
virObjectIsClass;
......
......@@ -367,20 +367,6 @@ virObjectUnref(void *anyobj)
}
/**
* virObjectAutoUnref:
*
* Helper used by VIR_AUTOUNREF
*/
void
virObjectAutoUnref(void *objptr)
{
virObjectPtr *obj = objptr;
virObjectUnref(*obj);
*obj = NULL;
}
/**
* virObjectRef:
* @anyobj: any instance of virObjectPtr
......
......@@ -109,21 +109,6 @@ virObjectNew(virClassPtr klass)
bool
virObjectUnref(void *obj);
void
virObjectAutoUnref(void *objptr);
/**
* VIR_AUTOUNREF:
* @type: type of an virObject subclass to be unref'd automatically
*
* DEPRECATED: Use g_autoptr(type) instead
*
* Declares a variable of @type which will be automatically unref'd when
* control goes out of the scope.
*/
#define VIR_AUTOUNREF(type) \
__attribute__((cleanup(virObjectAutoUnref))) type
G_DEFINE_AUTOPTR_CLEANUP_FUNC(virObject, virObjectUnref);
void *
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册