From d296f9f99daf102b9af5d56690e2bd00d61c1267 Mon Sep 17 00:00:00 2001 From: George Hazan Date: Tue, 24 Jul 2018 11:11:26 +0300 Subject: 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. --- plugins/XSoundNotify/src/dialog.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'plugins/XSoundNotify/src/dialog.cpp') diff --git a/plugins/XSoundNotify/src/dialog.cpp b/plugins/XSoundNotify/src/dialog.cpp index 32754d42c2..110e72a6d5 100644 --- a/plugins/XSoundNotify/src/dialog.cpp +++ b/plugins/XSoundNotify/src/dialog.cpp @@ -55,7 +55,7 @@ static INT_PTR CALLBACK DlgProcContactsOptions(HWND hwndDlg, UINT msg, WPARAM wP if (!db_get_ws(hContact, MODULENAME, SETTINGSKEY, &dbv)) { EnableWindow(GetDlgItem(hwndDlg, IDC_CONT_BUTTON_TEST_PLAY), TRUE); EnableWindow(GetDlgItem(hwndDlg, IDC_CONT_BUTTON_RESET_SOUND), TRUE); - SetDlgItemText(hwndDlg, IDC_CONT_LABEL_SOUND, PathFindFileName(dbv.ptszVal)); + SetDlgItemText(hwndDlg, IDC_CONT_LABEL_SOUND, PathFindFileName(dbv.pwszVal)); db_free(&dbv); } else { @@ -136,7 +136,7 @@ static INT_PTR CALLBACK DlgProcContactsOptions(HWND hwndDlg, UINT msg, WPARAM wP DBVARIANT dbv; if (!db_get_ws(hContact, MODULENAME, SETTINGSKEY, &dbv)) { wchar_t longpath[MAX_PATH] = { 0 }; - PathToAbsoluteW(dbv.ptszVal, longpath); + PathToAbsoluteW(dbv.pwszVal, longpath); Skin_PlaySoundFile(longpath); db_free(&dbv); } @@ -169,7 +169,7 @@ static INT_PTR CALLBACK DlgProcContactsOptions(HWND hwndDlg, UINT msg, WPARAM wP DBVARIANT dbv; if (!db_get_ws(hContact, MODULENAME, SETTINGSKEY, &dbv)) { wchar_t longpath[MAX_PATH]; - PathToAbsoluteW(dbv.ptszVal, longpath); + PathToAbsoluteW(dbv.pwszVal, longpath); XSN_Users.insert(new XSN_Data(hContact, longpath, IsDlgButtonChecked(hwndDlg, IDC_CONT_IGNORE_SOUND) ? 1 : 0, 1)); db_free(&dbv); } -- cgit v1.2.3