summaryrefslogtreecommitdiffstats
path: root/src/core/buffer.c
diff options
context:
space:
mode:
authorMichael Brown2006-03-23 20:33:57 +0100
committerMichael Brown2006-03-23 20:33:57 +0100
commitaf23ff8a24a9de9b725335527529e5cc743311eb (patch)
tree5208732478b9f9f1793931ad56adf2e394b7d324 /src/core/buffer.c
parentAdded missing #endif (diff)
downloadipxe-af23ff8a24a9de9b725335527529e5cc743311eb.tar.gz
ipxe-af23ff8a24a9de9b725335527529e5cc743311eb.tar.xz
ipxe-af23ff8a24a9de9b725335527529e5cc743311eb.zip
Assertions are now handled via the POSIX-like <assert.h>.
Diffstat (limited to 'src/core/buffer.c')
-rw-r--r--src/core/buffer.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/core/buffer.c b/src/core/buffer.c
index b1a0464e..5c31ff8d 100644
--- a/src/core/buffer.c
+++ b/src/core/buffer.c
@@ -42,6 +42,7 @@
#include "string.h"
#include "io.h"
#include "errno.h"
+#include <assert.h>
#include "buffer.h"
/**
@@ -208,7 +209,7 @@ int fill_buffer ( struct buffer *buffer, const void *data,
/* Write back 'before' block, if any */
if ( before.start ) {
before.tail = 0;
- ASSERT ( ( before.end - before.start ) >=
+ assert ( ( before.end - before.start ) >=
sizeof ( struct buffer_free_block ) );
store_free_block ( &before );
} else {
@@ -217,7 +218,7 @@ int fill_buffer ( struct buffer *buffer, const void *data,
/* Write back 'after' block, if any */
if ( after.start < buffer->end ) {
- ASSERT ( after.tail ||
+ assert ( after.tail ||
( ( after.end - after.start ) >=
sizeof ( struct buffer_free_block ) ) );
store_free_block ( &after );