From 7b8f98bcd9740862b5179fbd91b3fc6578752a10 Mon Sep 17 00:00:00 2001 From: Jeroen Bakker Date: Thu, 23 Mar 2023 07:53:16 +0100 Subject: [PATCH] Python: Limit BGL deprecation messages. This PR change the number of displayed BGL deprecation messages from 100 to 10. Fix: 105997 Pull Request: https://projects.blender.org/blender/blender/pulls/106018 --- source/blender/python/generic/bgl.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/source/blender/python/generic/bgl.c b/source/blender/python/generic/bgl.c index 4a5c68947c1..09fd23b6fa6 100644 --- a/source/blender/python/generic/bgl.c +++ b/source/blender/python/generic/bgl.c @@ -40,10 +40,10 @@ static CLG_LogRef LOG = {"bgl"}; static void report_deprecated_call(const char *function_name) { - /* Only report first 100 deprecated calls. BGL is typically used inside an handler that is + /* Only report first 10 deprecated calls. BGL is typically used inside an handler that is * triggered at refresh. */ static int times = 0; - while (times >= 100) { + while (times >= 10) { return; } char message[256]; -- 2.30.2