mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2026-04-30 23:48:05 +02:00
tui: newt: remove NULL checks after dereference
priv->start_buttons and priv->end_buttons are initialized at
construction and never changed and so the checks are not needed.
(cherry picked from commit 50ae9c936c)
This commit is contained in:
parent
fbdfc3f79c
commit
f7b1b1030b
1 changed files with 4 additions and 6 deletions
|
|
@ -262,12 +262,10 @@ nmt_newt_button_box_size_request (NmtNewtWidget *widget,
|
|||
size_request_buttons (bbox, priv->start_buttons, width, height);
|
||||
size_request_buttons (bbox, priv->end_buttons, width, height);
|
||||
|
||||
if (priv->start_buttons && priv->end_buttons) {
|
||||
if (priv->orientation == NMT_NEWT_BUTTON_BOX_HORIZONTAL)
|
||||
*width += 1;
|
||||
else
|
||||
*height += 1;
|
||||
}
|
||||
if (priv->orientation == NMT_NEWT_BUTTON_BOX_HORIZONTAL)
|
||||
*width += 1;
|
||||
else
|
||||
*height += 1;
|
||||
}
|
||||
|
||||
static void
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue