diff options
| author | Jeff Carr <[email protected]> | 2021-10-05 10:23:27 -0500 |
|---|---|---|
| committer | Jeff Carr <[email protected]> | 2021-10-05 10:23:27 -0500 |
| commit | 7ba7b97fa9d385e18c1f9636553db254f14383d0 (patch) | |
| tree | 973da9d78f143ffd9e7faab06fa9b67499f4fe0f /box.go | |
| parent | 11815517c6e566e47d3da61c4b852dd791dbd799 (diff) | |
BUG: fix potential 'nil' reference
Signed-off-by: Jeff Carr <[email protected]>
Diffstat (limited to 'box.go')
| -rw-r--r-- | box.go | 6 |
1 files changed, 6 insertions, 0 deletions
@@ -120,6 +120,12 @@ func HardBox(gw *GuiWindow, axis int, name string) *GuiBox { func HorizontalBreak(box *GuiBox) { log.Println("VerticalSeparator added to box =", box.Name) tmp := ui.NewHorizontalSeparator() + if (box == nil) { + return + } + if (box.UiBox == nil) { + return + } box.UiBox.Append(tmp, false) } |
