From 8d42211881a675bc1880e8c0de6a38b4035bfa8d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A1n=20Tomko?= Date: Wed, 16 Oct 2019 13:48:56 +0200 Subject: [PATCH] internal: delete VIR_STEAL_PTR MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Delete the macro to prevent its usage in new code. The GLib version should be used instead: p = g_steal_pointer(&ptr); Signed-off-by: Ján Tomko Reviewed-by: Michal Privoznik --- src/internal.h | 12 ------------ 1 file changed, 12 deletions(-) diff --git a/src/internal.h b/src/internal.h index 722cdbc57c..fb17b87baa 100644 --- a/src/internal.h +++ b/src/internal.h @@ -213,18 +213,6 @@ (a) = (a) ^ (b); \ } while (0) -/** - * VIR_STEAL_PTR: - * - * Steals pointer passed as second argument into the first argument. Second - * argument must not have side effects. - */ -#define VIR_STEAL_PTR(a, b) \ - do { \ - (a) = (b); \ - (b) = NULL; \ - } while (0) - /** * virCheckFlags: * @supported: an OR'ed set of supported flags