summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--cmake/eventfd_test.cpp2
-rw-r--r--data/example.conf3
-rw-r--r--modules/database/db_flatfile.cpp2
-rw-r--r--src/init.cpp3
4 files changed, 6 insertions, 4 deletions
diff --git a/cmake/eventfd_test.cpp b/cmake/eventfd_test.cpp
index 8abd9c381..ab45b653f 100644
--- a/cmake/eventfd_test.cpp
+++ b/cmake/eventfd_test.cpp
@@ -3,6 +3,6 @@
int main()
{
int i = eventfd(0, EFD_NONBLOCK);
- return i > 0 ? 1 : 0;
+ return i >= 0 ? 1 : 0;
}
diff --git a/data/example.conf b/data/example.conf
index 5d6e342ad..f38a84729 100644
--- a/data/example.conf
+++ b/data/example.conf
@@ -1058,6 +1058,9 @@ db_old
* [DEPRECATED] db_plain
*
* This is the flatfile database format from Anope-1.9.2 to Anope-1.9.5.
+ * To convert from this format, load both this db_flatfile. Be sure to name db_flatfile's
+ * target database to something else. Start Anope then shut down so the new database will be written.
+ * Then unload this and restart Anope, loading from the new database.
*/
#module { name = "db_plain" }
db_plain
diff --git a/modules/database/db_flatfile.cpp b/modules/database/db_flatfile.cpp
index b913b8529..639d6e1e8 100644
--- a/modules/database/db_flatfile.cpp
+++ b/modules/database/db_flatfile.cpp
@@ -84,7 +84,7 @@ class DBFlatFile : public Module
void OnReload()
{
ConfigReader config;
- DatabaseFile = config.ReadValue("flatfile", "database", "anope.db", 0);
+ DatabaseFile = config.ReadValue("db_flatfile", "database", "anope.db", 0);
}
EventReturn OnLoadDatabase()
diff --git a/src/init.cpp b/src/init.cpp
index e63f6793b..bcf49f00b 100644
--- a/src/init.cpp
+++ b/src/init.cpp
@@ -419,13 +419,12 @@ void Init(int ac, char **av)
Log(LOG_DEBUG_3) << "Top of fork() process loop";
SocketEngine::Process();
}
- SocketEngine::Shutdown();
exit(return_code);
}
else if (i == -1)
{
Log() << "Error, unable to fork: " << Anope::LastError();
- /* On a successful fork, the parents socket engine shutdown will eat these */
+ nofork = true;
delete sfe;
delete ssc;
}