Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions src/SQLiteNestedVFS.h
Original file line number Diff line number Diff line change
Expand Up @@ -999,6 +999,7 @@ class InnerDatabaseFile : public SQLiteVFS::File {
if (!read_only_) {
int rc;
if ((rc = Sync(0)) != SQLITE_OK) { // includes UpsertBarrier
SQLiteVFS::File::Close(); // deletes this
return rc;
}
outer_db_->exec("PRAGMA incremental_vacuum");
Expand Down Expand Up @@ -1110,7 +1111,7 @@ std::string urlencode(const std::string &s, bool keep_slash = false) {
} else {
escaped.append("%");
char buf[3];
sprintf(buf, "%.2X", s[i]);
sprintf(buf, "%.2X", static_cast<unsigned char>(s[i]));
escaped.append(buf);
}
}
Expand Down Expand Up @@ -1355,7 +1356,7 @@ class VFS : public SQLiteVFS::Wrapper {
return SQLITE_TOOBIG;
}
strncpy(zPathOut, inner_db_filename.c_str(), nPathOut - 1);
zPathOut[nPathOut] = 0;
zPathOut[nPathOut - 1] = 0;
SQLITE_VFS_LOG(4, "FullPathname " << zName2 << " => " << zPathOut)
return SQLITE_OK;
}
Expand Down
Loading