diff options
author | lethality <lethality@anope.org> | 2012-10-05 15:15:50 +0100 |
---|---|---|
committer | lethality <lethality@anope.org> | 2012-10-05 15:15:50 +0100 |
commit | 94fc2ba9c927f8950d81e38ef6b962ee5af022df (patch) | |
tree | 0e2ebe2df3ed41e5c7c10aba46bab236d3e11b75 /src/misc.cpp | |
parent | 2f87b8e430f5082708d7229b92c10b20f9e98fdf (diff) | |
parent | eff61c7a9708013f9617282c4f327bbe2b1bfb79 (diff) |
Merge branch '1.9' of ssh://anope.git.sf.net/gitroot/anope/anope into 1.9
Diffstat (limited to 'src/misc.cpp')
-rw-r--r-- | src/misc.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/misc.cpp b/src/misc.cpp index 1245656f0..cd7516b76 100644 --- a/src/misc.cpp +++ b/src/misc.cpp @@ -773,7 +773,7 @@ void Anope::Unhex(const Anope::string &src, char *dest, size_t sz) Anope::string d; Anope::Unhex(src, d); - strncpy(dest, d.c_str(), sz); + memcpy(dest, d.c_str(), std::min(d.length() + 1, sz)); } int Anope::LastErrorCode() |