Skip to content

Commit

Permalink
Buffer handling fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
rlerdorf committed Jul 16, 2009
1 parent 29fb4ab commit f5980b7
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions ext/interbase/interbase.c
Expand Up @@ -861,8 +861,8 @@ static char const dpb_args[] = {

int _php_ibase_attach_db(char **args, int *len, long *largs, isc_db_handle *db TSRMLS_DC)
{
short i, dpb_len, buf_len = 256;
char dpb_buffer[256] = { isc_dpb_version1 }, *dpb;
short i, dpb_len, buf_len = 257-2; /* version byte at the front, and a null at the end */
char dpb_buffer[257] = { isc_dpb_version1, 0 }, *dpb;

dpb = dpb_buffer + 1;

Expand Down

0 comments on commit f5980b7

Please sign in to comment.