summaryrefslogtreecommitdiff
path: root/ext/json/fbuffer/fbuffer.h
diff options
context:
space:
mode:
Diffstat (limited to 'ext/json/fbuffer/fbuffer.h')
-rw-r--r--ext/json/fbuffer/fbuffer.h8
1 files changed, 2 insertions, 6 deletions
diff --git a/ext/json/fbuffer/fbuffer.h b/ext/json/fbuffer/fbuffer.h
index b5e47ee..af74187 100644
--- a/ext/json/fbuffer/fbuffer.h
+++ b/ext/json/fbuffer/fbuffer.h
@@ -3,7 +3,6 @@
#define _FBUFFER_H_
#include "ruby.h"
-#include <assert.h>
#ifndef RHASH_SIZE
#define RHASH_SIZE(hsh) (RHASH(hsh)->tbl->num_entries)
@@ -166,11 +165,8 @@ static FBuffer *fbuffer_dup(FBuffer *fb)
unsigned long len = fb->len;
FBuffer *result;
- assert(len > 0);
- if (len > 0) {
- result = fbuffer_alloc(len);
- fbuffer_append(result, FBUFFER_PAIR(fb));
- }
+ result = fbuffer_alloc(len);
+ fbuffer_append(result, FBUFFER_PAIR(fb));
return result;
}