代码拉取完成,页面将自动刷新
From e3dccd88d90f0b822ed815cb9a43e84c961a92f9 Mon Sep 17 00:00:00 2001
From: Chris Lumens <clumens@redhat.com>
Date: Thu, 11 Jul 2024 10:33:02 -0400
Subject: [PATCH 2/5] Refactor: Add three argument versions of
FOREACH_{NODE,TICKET}.
These take an additional argument that is the config object. Nothing
uses these at the moment - I'm going to move callers from the old
renamed versions to these over a bunch of commits.
---
src/ticket.h | 11 +++++++++++
1 file changed, 11 insertions(+)
diff --git a/src/ticket.h b/src/ticket.h
index af4b195..dc6869e 100644
--- a/src/ticket.h
+++ b/src/ticket.h
@@ -35,6 +35,17 @@ extern int TIME_RES;
#define DEFAULT_RETRIES 10
+#define FOREACH_TICKET(b_, i_, t_) \
+ for (i_ = 0; \
+ (t_ = (b_)->ticket + i_, i_ < (b_)->ticket_count); \
+ i_++)
+
+#define FOREACH_NODE(b_, i_, n_) \
+ for (i_ = 0; \
+ (n_ = (b_)->site + i_, i_ < (b_)->site_count); \
+ i_++)
+
+
#define _FOREACH_TICKET(i_, t_) \
for (i_ = 0; \
(t_ = booth_conf->ticket + i_, i_ < booth_conf->ticket_count); \
--
2.25.1
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。