-
Notifications
You must be signed in to change notification settings - Fork 374
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
implement throwing exception when ATTR_PERSISTENT is in connection #324
Conversation
…n options; added tests
$dsn = "sqlsrv:Server = $serverName;Database = $database;"; | ||
try{ | ||
echo "Testing a connection with ATTR_PREFETCH before ERRMODE_EXCEPTION...\n"; | ||
// setting PDO::ATTR_PERSISTENT in PDO constructor returns an exception |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
comment is ATTR_PERSISTENT
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
since this is a fix for heap corruption in PDO, please run valgrind/Dr.Memory to verify that memory hasn't leaked after throwing the exception, in the presence of try catch block or in the absence of it
fix for #65
fix by throwing exception when ATTR_PERSISTENT is in connection option
added test