Linux DTrace development list
 help / color / mirror / Atom feed
* [PATCH 1/8] list: add dt_list_empty()
@ 2026-09-28 18:01 Kris Van Hees
  2026-10-03  8:39 ` [DTrace-devel] " Elena Zannoni
  0 siblings, 1 reply; 2+ messages in thread
From: Kris Van Hees @ 2026-09-28 18:01 UTC (permalink / raw)
  To: dtrace, dtrace-devel

Signed-off-by: Kris Van Hees <kris.van.hees@oracle.com>
---
 libcommon/dt_list.h | 1 +
 1 file changed, 1 insertion(+)

diff --git a/libcommon/dt_list.h b/libcommon/dt_list.h
index e6d4c863..ffe0b963 100644
--- a/libcommon/dt_list.h
+++ b/libcommon/dt_list.h
@@ -19,6 +19,7 @@ typedef struct dt_list {
 
 #define	dt_list_prev(elem)	((void *)(((dt_list_t *)(elem))->dl_prev))
 #define	dt_list_next(elem)	((void *)(((dt_list_t *)(elem))->dl_next))
+#define dt_list_empty(elem)	(dt_list_next(elem) == NULL)
 
 #define dt_in_list(l, e)	(dt_list_next(l) == (e) || dt_list_prev(e))
 
-- 
2.52.0


^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2026-10-03  8:39 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-09-28 18:01 [PATCH 1/8] list: add dt_list_empty() Kris Van Hees
2026-10-03  8:39 ` [DTrace-devel] " Elena Zannoni

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox