diff options
author | George Hazan <ghazan@miranda.im> | 2018-07-24 11:11:26 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2018-07-24 11:11:26 +0300 |
commit | d296f9f99daf102b9af5d56690e2bd00d61c1267 (patch) | |
tree | 39311caaf80abf0b47ecb78cf94dc8157b193575 /src/core/stdmsg | |
parent | ffc521e5d5e9bd66feb65afe0046b3fc7e073356 (diff) |
database:
- senseless fiels ptszVal removed from DBVARIANT, pwszVal is used instead;
- if you want db_get to return a string, you need to use db_get_s.
Diffstat (limited to 'src/core/stdmsg')
-rw-r--r-- | src/core/stdmsg/src/chat_options.cpp | 2 | ||||
-rw-r--r-- | src/core/stdmsg/src/msgdialog.cpp | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/src/core/stdmsg/src/chat_options.cpp b/src/core/stdmsg/src/chat_options.cpp index fc7258ce76..932ca3f07b 100644 --- a/src/core/stdmsg/src/chat_options.cpp +++ b/src/core/stdmsg/src/chat_options.cpp @@ -204,7 +204,7 @@ static void InitSetting(wchar_t** ppPointer, char* pszSetting, wchar_t* pszDefau { DBVARIANT dbv; if (!db_get_ws(0, CHAT_MODULE, pszSetting, &dbv)) { - replaceStrW(*ppPointer, dbv.ptszVal); + replaceStrW(*ppPointer, dbv.pwszVal); db_free(&dbv); } else replaceStrW(*ppPointer, pszDefault); diff --git a/src/core/stdmsg/src/msgdialog.cpp b/src/core/stdmsg/src/msgdialog.cpp index cfb4c8d556..57711e2228 100644 --- a/src/core/stdmsg/src/msgdialog.cpp +++ b/src/core/stdmsg/src/msgdialog.cpp @@ -219,8 +219,8 @@ bool CSrmmWindow::OnInitDialog() if (m_hContact) {
DBVARIANT dbv;
if (!db_get_ws(m_hContact, SRMSGMOD, DBSAVEDMSG, &dbv)) {
- if (dbv.ptszVal[0]) {
- m_message.SetText(dbv.ptszVal);
+ if (dbv.pwszVal[0]) {
+ m_message.SetText(dbv.pwszVal);
m_btnOk.Enable(true);
UpdateReadChars();
PostMessage(m_message.GetHwnd(), EM_SETSEL, -1, -1);
|