Applied the patch supplied by Andy to avoid issues with SQLite.