summaryrefslogtreecommitdiff
path: root/src/piece-table.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/piece-table.c')
-rw-r--r--src/piece-table.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/src/piece-table.c b/src/piece-table.c
index 070d265..14f456f 100644
--- a/src/piece-table.c
+++ b/src/piece-table.c
@@ -159,15 +159,11 @@ void
piece_table_insert (piece_table *pt, size_t pos, char *in, size_t len)
{
piece *start, *end, *new;
- size_t i;
assert ( pos <= pt->length );
assert ( len > 0 );
- for (i=0; i<len; i++)
- {
- text_buffer_append (&pt->add, in[i]);
- }
+ text_buffer_append_str (&pt->add, in, len);
if ( pos == 0 )
{