Skip to content

Commit ee20ea8

Browse files
committed
inputcapture: Stop separating call_last_unref() from call_dispose()
Signed-off-by: Simon McVittie <smcv@debian.org>
1 parent d5bbec2 commit ee20ea8

File tree

1 file changed

+4
-11
lines changed

1 file changed

+4
-11
lines changed

libportal/inputcapture.c

Lines changed: 4 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -239,8 +239,10 @@ static void create_session (Call *call);
239239
static void get_zones (Call *call);
240240

241241
static void
242-
call_dispose (Call *call)
242+
call_dispose (void *p)
243243
{
244+
Call *call = p;
245+
244246
/* CreateSesssion */
245247
if (call->parent)
246248
call->parent->parent_unexport (call->parent);
@@ -270,19 +272,10 @@ call_ref (Call *call)
270272
return g_rc_box_acquire (call);
271273
}
272274

273-
static inline void
274-
call_last_unref (void *call)
275-
{
276-
/* Only separated from call_dispose() because g_rc_box_release_full()
277-
* wants a GDestroyNotify, and because this is a convenient place to put
278-
* life-cycle debugging */
279-
call_dispose (call);
280-
}
281-
282275
static inline void
283276
call_unref (void *call)
284277
{
285-
g_rc_box_release_full (call, call_last_unref);
278+
g_rc_box_release_full (call, call_dispose);
286279
}
287280

288281
G_DEFINE_AUTOPTR_CLEANUP_FUNC (Call, call_unref)

0 commit comments

Comments
 (0)