summaryrefslogtreecommitdiff
path: root/plugins/AutoShutdown
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/AutoShutdown')
-rw-r--r--plugins/AutoShutdown/src/settingsdlg.cpp4
-rw-r--r--plugins/AutoShutdown/src/watcher.cpp6
2 files changed, 5 insertions, 5 deletions
diff --git a/plugins/AutoShutdown/src/settingsdlg.cpp b/plugins/AutoShutdown/src/settingsdlg.cpp
index 3e59a08882..3109286671 100644
--- a/plugins/AutoShutdown/src/settingsdlg.cpp
+++ b/plugins/AutoShutdown/src/settingsdlg.cpp
@@ -123,8 +123,8 @@ static INT_PTR CALLBACK SettingsDlgProc(HWND hwndDlg, UINT msg, WPARAM wParam, L
{
DBVARIANT dbv;
if (!db_get_ws(NULL, MODULENAME, "Message", &dbv)) {
- SetDlgItemText(hwndDlg, IDC_EDIT_MESSAGE, dbv.ptszVal);
- mir_free(dbv.ptszVal);
+ SetDlgItemText(hwndDlg, IDC_EDIT_MESSAGE, dbv.pwszVal);
+ mir_free(dbv.pwszVal);
}
}
/* cpuusage threshold */
diff --git a/plugins/AutoShutdown/src/watcher.cpp b/plugins/AutoShutdown/src/watcher.cpp
index fbd2987e8b..529954f758 100644
--- a/plugins/AutoShutdown/src/watcher.cpp
+++ b/plugins/AutoShutdown/src/watcher.cpp
@@ -100,11 +100,11 @@ static int MsgEventAdded(WPARAM, LPARAM hDbEvent)
if (dbe.eventType == EVENTTYPE_MESSAGE && !(dbe.flags & DBEF_SENT)) {
DBVARIANT dbv;
if (!db_get_ws(NULL, MODULENAME, "Message", &dbv)) {
- TrimString(dbv.ptszVal);
+ TrimString(dbv.pwszVal);
wchar_t *pszMsg = GetMessageText(&dbe.pBlob, &dbe.cbBlob);
- if (pszMsg != nullptr && wcsstr(pszMsg, dbv.ptszVal) != nullptr)
+ if (pszMsg != nullptr && wcsstr(pszMsg, dbv.pwszVal) != nullptr)
ShutdownAndStopWatcher(); /* msg with specified text recvd */
- mir_free(dbv.ptszVal); /* does NULL check */
+ mir_free(dbv.pwszVal); /* does NULL check */
}
}
mir_free(dbe.pBlob);