Hello,

It seems that VS 2013 has grown stricter by default in treating potentially 
security-related warnings as errors. Some context here:
    
http://blogs.msdn.com/b/sdl/archive/2012/06/06/warnings-sdl-and-improving-uninitialized-variable-detection.aspx

When building the Release configuration for a project containing the SQLite 
3.8.3 amalgamation, it emits the following warnings as errors by default:
    sqlite3.c(41085): error C4703: potentially uninitialized local pointer 
variable 'p' used
    sqlite3.c(45247): error C4703: potentially uninitialized local pointer 
variable 'p' used
    sqlite3.c(45230): error C4703: potentially uninitialized local pointer 
variable 'p' used
    sqlite3.c(46156): error C4703: potentially uninitialized local pointer 
variable 'p' used

Initializing the local variable p to NULL in pager_lookup avoids these.

In my setup, sqlite3.c was built from a project created from the VS 2013 
"Static Library (Windows Store apps)" template. The errors were emitted from 
code generation for a second project created from the "Unit Test Library 
(Windows Store apps)" template that links the static library. Both projects 
were using the warning configuration defaults from those templates: /W3 /WX- 
/sdl .

A search for 'sqllite C4703' suggests a handful of folks have encountered this 
and worked around it in a few ways. However, I couldn't find any indication in 
the list of tickets or history of pager.c that this is tracked / fixed at the 
source.

Please let me know if you'd like me to enter a new ticket to track the minor 
change to avoid these warnings. Thank you for contributing this excellent 
library to the public domain.

Regards,
- Bryan

_______________________________________________
sqlite-users mailing list
[email protected]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to