We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4e0134c commit fece24fCopy full SHA for fece24f
ext/sqlite3/sqlite3.c
@@ -123,7 +123,8 @@ PHP_METHOD(sqlite3, open)
123
if (strlen(filename) != filename_len) {
124
return;
125
}
126
- if (memcmp(filename, ":memory:", sizeof(":memory:")) != 0) {
+ if (filename_len != sizeof(":memory:")-1 ||
127
+ memcmp(filename, ":memory:", sizeof(":memory:")-1) != 0) {
128
if (!(fullpath = expand_filepath(filename, NULL TSRMLS_CC))) {
129
zend_throw_exception(zend_exception_get_default(TSRMLS_C), "Unable to expand filepath", 0 TSRMLS_CC);
130
0 commit comments