summaryrefslogtreecommitdiff
path: root/ext/sybase/php_sybase_db.c
diff options
context:
space:
mode:
authorJoey Smith <joey@php.net>2000-10-19 16:09:30 +0000
committerJoey Smith <joey@php.net>2000-10-19 16:09:30 +0000
commitdc44e06eeb9fe182e1178740d032d1aa073da6d6 (patch)
treefefeb77da5588efd62a011aba36b1e49bcd1b165 /ext/sybase/php_sybase_db.c
parenta57ea792c69e27e20fd2db8a01aadb037abec137 (diff)
downloadphp-git-dc44e06eeb9fe182e1178740d032d1aa073da6d6.tar.gz
Fix #7338.
Diffstat (limited to 'ext/sybase/php_sybase_db.c')
-rw-r--r--ext/sybase/php_sybase_db.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/ext/sybase/php_sybase_db.c b/ext/sybase/php_sybase_db.c
index 2b7d349f04..ef6c83632d 100644
--- a/ext/sybase/php_sybase_db.c
+++ b/ext/sybase/php_sybase_db.c
@@ -274,7 +274,7 @@ static void php_sybase_do_connect(INTERNAL_FUNCTION_PARAMETERS,int persistent)
}
convert_to_string(yyhost);
host = yyhost->value.str.val;
- user=passwd=NULL;
+ user=passwd=charset=NULL;
hashed_details_length = yyhost->value.str.len+6+3;
hashed_details = (char *) emalloc(hashed_details_length+1);
sprintf(hashed_details,"sybase_%s__",yyhost->value.str.val);
@@ -290,7 +290,7 @@ static void php_sybase_do_connect(INTERNAL_FUNCTION_PARAMETERS,int persistent)
convert_to_string(yyuser);
host = yyhost->value.str.val;
user = yyuser->value.str.val;
- passwd=NULL;
+ passwd=charset=NULL;
hashed_details_length = yyhost->value.str.len+yyuser->value.str.len+6+3;
hashed_details = (char *) emalloc(hashed_details_length+1);
sprintf(hashed_details,"sybase_%s_%s_",yyhost->value.str.val,yyuser->value.str.val);
@@ -308,6 +308,7 @@ static void php_sybase_do_connect(INTERNAL_FUNCTION_PARAMETERS,int persistent)
host = yyhost->value.str.val;
user = yyuser->value.str.val;
passwd = yypasswd->value.str.val;
+ charset = NULL;
hashed_details_length = yyhost->value.str.len+yyuser->value.str.len+yypasswd->value.str.len+6+3;
hashed_details = (char *) emalloc(hashed_details_length+1);
sprintf(hashed_details,"sybase_%s_%s_%s",yyhost->value.str.val,yyuser->value.str.val,yypasswd->value.str.val); /* SAFE */