diff options
author | Kirill Volinsky <mataes2007@gmail.com> | 2018-03-11 17:26:39 +0300 |
---|---|---|
committer | Kirill Volinsky <mataes2007@gmail.com> | 2018-03-11 17:26:39 +0300 |
commit | faa5fc757a25eeeaf57ff35ae908702d22d68163 (patch) | |
tree | 7834e1a4e1deee4b1f1cd173c8ac96828fc0b805 /plugins/Alarms/src/alarm_win.cpp | |
parent | 51dc3cf5e392c4ffc5da165e8559f8cc330bc0b7 (diff) |
Alarms: use strncpy_s and wcsncpy_s instead of mir_wstrcpy and mir_strcpy
Diffstat (limited to 'plugins/Alarms/src/alarm_win.cpp')
-rw-r--r-- | plugins/Alarms/src/alarm_win.cpp | 32 |
1 files changed, 16 insertions, 16 deletions
diff --git a/plugins/Alarms/src/alarm_win.cpp b/plugins/Alarms/src/alarm_win.cpp index f47f1f566d..1eb844c870 100644 --- a/plugins/Alarms/src/alarm_win.cpp +++ b/plugins/Alarms/src/alarm_win.cpp @@ -349,32 +349,32 @@ int ReloadFonts(WPARAM, LPARAM) int AlarmWinModulesLoaded(WPARAM, LPARAM)
{
title_font_id.cbSize = sizeof(FontIDW);
- mir_wstrcpy(title_font_id.group, LPGENW("Alarms"));
- mir_wstrcpy(title_font_id.name, LPGENW("Title"));
- mir_strcpy(title_font_id.dbSettingsGroup, MODULE);
- mir_strcpy(title_font_id.prefix, "FontTitle");
- mir_wstrcpy(title_font_id.backgroundGroup, LPGENW("Alarms"));
- mir_wstrcpy(title_font_id.backgroundName, LPGENW("Background"));
+ wcsncpy_s(title_font_id.group, LPGENW("Alarms"), _TRUNCATE);
+ wcsncpy_s(title_font_id.name, LPGENW("Title"), _TRUNCATE);
+ strncpy_s(title_font_id.dbSettingsGroup, MODULE, _TRUNCATE);
+ strncpy_s(title_font_id.prefix, "FontTitle", _TRUNCATE);
+ wcsncpy_s(title_font_id.backgroundGroup, LPGENW("Alarms"), _TRUNCATE);
+ wcsncpy_s(title_font_id.backgroundName, LPGENW("Background"), _TRUNCATE);
title_font_id.flags = 0;
title_font_id.order = 0;
Font_RegisterW(&title_font_id);
window_font_id.cbSize = sizeof(FontIDW);
- mir_wstrcpy(window_font_id.group, LPGENW("Alarms"));
- mir_wstrcpy(window_font_id.name, LPGENW("Window"));
- mir_strcpy(window_font_id.dbSettingsGroup, MODULE);
- mir_strcpy(window_font_id.prefix, "FontWindow");
- mir_wstrcpy(window_font_id.backgroundGroup, LPGENW("Alarms"));
- mir_wstrcpy(window_font_id.backgroundName, LPGENW("Background"));
+ wcsncpy_s(window_font_id.group, LPGENW("Alarms"), _TRUNCATE);
+ wcsncpy_s(window_font_id.name, LPGENW("Window"), _TRUNCATE);
+ strncpy_s(window_font_id.dbSettingsGroup, MODULE, _TRUNCATE);
+ strncpy_s(window_font_id.prefix, "FontWindow", _TRUNCATE);
+ wcsncpy_s(window_font_id.backgroundGroup, LPGENW("Alarms"), _TRUNCATE);
+ wcsncpy_s(window_font_id.backgroundName, LPGENW("Background"), _TRUNCATE);
window_font_id.flags = 0;
window_font_id.order = 1;
Font_RegisterW(&window_font_id);
bk_colour_id.cbSize = sizeof(ColourIDW);
- mir_strcpy(bk_colour_id.dbSettingsGroup, MODULE);
- mir_wstrcpy(bk_colour_id.group, LPGENW("Alarms"));
- mir_wstrcpy(bk_colour_id.name, LPGENW("Background"));
- mir_strcpy(bk_colour_id.setting, "BkColour");
+ strncpy_s(bk_colour_id.dbSettingsGroup, MODULE, _TRUNCATE);
+ wcsncpy_s(bk_colour_id.group, LPGENW("Alarms"), _TRUNCATE);
+ wcsncpy_s(bk_colour_id.name, LPGENW("Background"), _TRUNCATE);
+ strncpy_s(bk_colour_id.setting, "BkColour", _TRUNCATE);
bk_colour_id.defcolour = GetSysColor(COLOR_3DFACE);
bk_colour_id.flags = 0;
bk_colour_id.order = 0;
|