Skip to content

Commit 0b75a57

Browse files
authored
chore: enable more SDL flags (#51)
1 parent 1c78293 commit 0b75a57

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

binding.gyp

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,13 +23,14 @@
2323
"VCCLCompilerTool": {
2424
"AdditionalOptions": [
2525
"/guard:cf",
26-
"/w34244",
27-
"/we4267",
26+
"/sdl",
27+
"/W3",
2828
"/ZH:SHA_256"
2929
]
3030
},
3131
"VCLinkerTool": {
3232
"AdditionalOptions": [
33+
"/DYNAMICBASE",
3334
"/guard:cf"
3435
]
3536
}

src/statement.h

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,9 @@ namespace Values {
5252
template <class T> inline Blob(T _name, size_t len, const void* val) :
5353
Field(_name, SQLITE_BLOB), length(len) {
5454
value = (char*)malloc(len);
55-
memcpy(value, val, len);
55+
if (value) {
56+
memcpy(value, val, len);
57+
}
5658
}
5759
inline ~Blob() {
5860
free(value);

0 commit comments

Comments
 (0)