Skip to content

Commit 4cf5bd8

Browse files
committed
Turn on the asserts in ringbuf for debug builds
1 parent bffe0f4 commit 4cf5bd8

File tree

2 files changed

+5
-0
lines changed

2 files changed

+5
-0
lines changed

kitty/ringbuf.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,9 @@
1313
* <http://creativecommons.org/publicdomain/zero/1.0/>.
1414
*/
1515

16+
#ifndef KITTY_DEBUG_BUILD
1617
#define NDEBUG 1
18+
#endif
1719
#include "ringbuf.h"
1820

1921
#include <stdint.h>

setup.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -304,6 +304,9 @@ def init_env(
304304
cflags.append('-flto')
305305
ldflags.append('-flto')
306306

307+
if debug:
308+
cflags.append('-DKITTY_DEBUG_BUILD')
309+
307310
if profile:
308311
cppflags.append('-DWITH_PROFILER')
309312
cflags.append('-g3')

0 commit comments

Comments
 (0)