summaryrefslogtreecommitdiff
path: root/src/dynamic.cpp
diff options
context:
space:
mode:
authordanieldg <danieldg@e03df62e-2008-0410-955e-edbf42e46eb7>2010-01-14 18:17:08 +0000
committerdanieldg <danieldg@e03df62e-2008-0410-955e-edbf42e46eb7>2010-01-14 18:17:08 +0000
commit601d67fd5f5a9e430a59a1930382eae67eb39fb4 (patch)
tree7dd07ff306540097f70b6689feca83f60ac002a5 /src/dynamic.cpp
parent7866c42d8f80723d07cf38ed9413857164b55e00 (diff)
Move revision information from Version object to a static symbol
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@12256 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/dynamic.cpp')
-rw-r--r--src/dynamic.cpp13
1 files changed, 12 insertions, 1 deletions
diff --git a/src/dynamic.cpp b/src/dynamic.cpp
index 719046dbe..ebaaa5191 100644
--- a/src/dynamic.cpp
+++ b/src/dynamic.cpp
@@ -45,7 +45,7 @@ union init_t {
Module* (*fptr)();
};
-Module* DLLManager::callInit()
+Module* DLLManager::CallInit()
{
if (!h)
return NULL;
@@ -60,3 +60,14 @@ Module* DLLManager::callInit()
return (*initfn.fptr)();
}
+
+std::string DLLManager::GetVersion()
+{
+ if (!h)
+ return "";
+
+ const char* srcver = (char*)dlsym(h, "inspircd_src_version");
+ if (srcver)
+ return srcver;
+ return "Unversioned module";
+}