Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
namecoinq committed Oct 29, 2013
2 parents b2eb918 + 3027e8c commit 5b00e68
Show file tree
Hide file tree
Showing 7 changed files with 417 additions and 113 deletions.
2 changes: 1 addition & 1 deletion namecoin-qt.pro
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
TEMPLATE = app
TARGET = namecoin-qt
macx:TARGET = "Namecoin-Qt"
VERSION = 0.3.71
VERSION = 0.3.72
INCLUDEPATH += src src/json src/qt
QT += network
DEFINES += GUI QT_GUI BOOST_THREAD_USE_LIB BOOST_SPIRIT_THREADSAFE
Expand Down
2 changes: 1 addition & 1 deletion src/db.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,7 @@ void CDB::Close()
--mapFileUseCount[strFile];
}

void static CloseDb(const string& strFile)
static void CloseDb(const string& strFile)
{
CRITICAL_BLOCK(cs_db)
{
Expand Down
17 changes: 12 additions & 5 deletions src/init.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -529,13 +529,20 @@ bool AppInit2(int argc, char* argv[])

RandAddSeedPerfmon();

filesystem::path nameindexfile = filesystem::path(GetDataDir()) / "nameindexfull.dat";
if (!filesystem::exists(nameindexfile))
{
//PrintConsole("Scanning blockchain for names to create fast index...");
filesystem::path nameindexfile_old = filesystem::path(GetDataDir()) / "nameindexfull.dat";
filesystem::path nameindexfile = filesystem::path(GetDataDir()) / "nameindex.dat";

if (filesystem::exists(nameindexfile_old))
{
// If old file exists - delete it and recan
filesystem::remove(nameindexfile_old);
// Also delete new file if it exists together with the old one, as it could be the one from a much older version
if (filesystem::exists(nameindexfile))
filesystem::remove(nameindexfile);
rescanfornames();
//PrintConsole("\n");
}
else if (!filesystem::exists(nameindexfile))
rescanfornames();

if (!CreateThread(StartNode, NULL))
wxMessageBox("Error: CreateThread(StartNode) failed", "Namecoin");
Expand Down
Loading

0 comments on commit 5b00e68

Please sign in to comment.