From 1bd96217090967cb8e0a454c3fcaecd43fb92b3d Mon Sep 17 00:00:00 2001 From: Christophe CURIS Date: Sat, 29 Nov 2014 16:35:24 +0100 Subject: [PATCH] wmaker: do not store return value that we don't use (Coverity #50252) As pointed by Coverity, we store a value into the variable 'entry' but we never use it later, although we re-use the variable. For the maintainability of the code, it is not really good as it could mislead into thinking the value could be used, so this patch removes the assignation. Signed-off-by: Christophe CURIS --- src/dock.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/dock.c b/src/dock.c index 8b135689..8853fa3f 100644 --- a/src/dock.c +++ b/src/dock.c @@ -1220,9 +1220,9 @@ static WMenu *dockMenuCreate(WScreen *scr, int type) scr->dock_pos_menu = makeDockPositionMenu(scr); wMenuEntrySetCascade(menu, entry, scr->dock_pos_menu); - if (!wPreferences.flags.nodrawer) { - entry = wMenuAddCallback(menu, _("Add a drawer"), addADrawerCallback, NULL); - } + if (!wPreferences.flags.nodrawer) + wMenuAddCallback(menu, _("Add a drawer"), addADrawerCallback, NULL); + } else { if (type == WM_CLIP) entry = wMenuAddCallback(menu, _("Clip Options"), NULL, NULL);