X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/58ac79d31715b36a824ea11ca577babac9ad309d..396825dced4558d8d724d0e38f7e1017f76d0a96:/src/common/utilscmn.cpp diff --git a/src/common/utilscmn.cpp b/src/common/utilscmn.cpp index deffb94e27..43826ac40f 100644 --- a/src/common/utilscmn.cpp +++ b/src/common/utilscmn.cpp @@ -436,8 +436,7 @@ bool wxGetEmailAddress(wxChar *address, int maxSize) if ( !email ) return false; - wxStrncpy(address, email, maxSize - 1); - address[maxSize - 1] = wxT('\0'); + wxStrlcpy(address, email.t_str(), maxSize); return true; }