summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/cull_list.cpp13
-rwxr-xr-xsrc/svn-rev.sh2
2 files changed, 10 insertions, 5 deletions
diff --git a/src/cull_list.cpp b/src/cull_list.cpp
index b7254fd0b..0951a3224 100644
--- a/src/cull_list.cpp
+++ b/src/cull_list.cpp
@@ -84,13 +84,18 @@ bool CullList::IsValid(userrec* user)
CullItem::CullItem(userrec* u, std::string &r)
{
this->user = u;
- this->reason = r;
+ this->reason = strdup(r.c_str());
}
CullItem::CullItem(userrec* u, const char* r)
{
this->user = u;
- this->reason = r;
+ this->reason = strdup(r);
+}
+
+CullItem::~CullItem()
+{
+ free(reason);
}
userrec* CullItem::GetUser()
@@ -98,7 +103,7 @@ userrec* CullItem::GetUser()
return this->user;
}
-std::string CullItem::GetReason()
+const char* CullItem::GetReason()
{
return this->reason;
}
@@ -145,7 +150,7 @@ int CullList::Apply()
*/
if (IsValid(u))
{
- kill_link(u,a->GetReason().c_str());
+ kill_link(u,a->GetReason());
list.erase(list.begin());
/* So that huge numbers of quits dont block,
* we yield back to our mainloop every 15
diff --git a/src/svn-rev.sh b/src/svn-rev.sh
index c9ebce74d..8b1f627c1 100755
--- a/src/svn-rev.sh
+++ b/src/svn-rev.sh
@@ -1 +1 @@
-echo 3623
+echo 3625