Browse Source

mac-syphon: Replace source addref calls with get_ref

Jim 3 years ago
parent
commit
404ebdbd51
1 changed files with 3 additions and 2 deletions
  1. 3 2
      plugins/mac-syphon/syphon.m

+ 3 - 2
plugins/mac-syphon/syphon.m

@@ -892,8 +892,9 @@ static void syphon_release(void *param)
 
 static inline obs_properties_t *syphon_properties_internal(syphon_t s)
 {
-	if (s)
-		obs_source_addref(s->source);
+	if (s && obs_source_get_ref(s->source) == NULL) {
+		s = NULL;
+	}
 
 	obs_properties_t *props =
 		obs_properties_create_param(s, syphon_release);