mirror of
https://github.com/gryf/wmaker.git
synced 2026-01-11 17:04:15 +01:00
fixed a buffer overflow
This commit is contained in:
@@ -44,6 +44,7 @@ Changes since version 0.80.0:
|
||||
- Fixed a bug in wdread
|
||||
- Fixed bug with windows that have WM_HINTS.take_focus = False. These windows
|
||||
will not receive focus at all.
|
||||
- Fixed a buffer overflow in winmenu.c
|
||||
|
||||
|
||||
Changes since version 0.70.0:
|
||||
|
||||
@@ -239,12 +239,12 @@ updateWorkspaceMenu(WMenu *menu)
|
||||
if (i < menu->entry_no) {
|
||||
if (strcmp(menu->entries[i]->text,scr->workspaces[i]->name)!=0) {
|
||||
wfree(menu->entries[i]->text);
|
||||
strcpy(title, scr->workspaces[i]->name);
|
||||
strncpy(title, scr->workspaces[i]->name, MAX_WORKSPACENAME_WIDTH);
|
||||
menu->entries[i]->text = wstrdup(title);
|
||||
menu->flags.realized = 0;
|
||||
}
|
||||
} else {
|
||||
strcpy(title, scr->workspaces[i]->name);
|
||||
strncpy(title, scr->workspaces[i]->name, MAX_WORKSPACENAME_WIDTH);
|
||||
|
||||
wMenuAddCallback(menu, title, switchWSCommand, NULL);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user