Skip to content

Commit

Permalink
Merge pull request #338 from doublec/htable_overrun
Browse files Browse the repository at this point in the history
htable: Fix buffer overrun in htable_rpc_list
  • Loading branch information
miconda committed Sep 23, 2015
2 parents 0678f51 + 1c16447 commit e9c2022
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion modules/htable/htable.c
Expand Up @@ -1044,7 +1044,7 @@ static void htable_rpc_list(rpc_t* rpc, void* c)
if (ht->dbtable.len > 0) {
len = ht->dbtable.len > 127 ? 127 : ht->dbtable.len;
memcpy(dbname, ht->dbtable.s, len);
dbname[ht->dbtable.len] = '\0';
dbname[len] = '\0';
} else {
dbname[0] = '\0';
}
Expand Down

0 comments on commit e9c2022

Please sign in to comment.