From owner-dev-commits-src-all@freebsd.org Sun Jan 10 22:29:51 2021 Return-Path: Delivered-To: dev-commits-src-all@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 123D04DC1B8; Sun, 10 Jan 2021 22:29:51 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4DDWjp6Cvrz3p8G; Sun, 10 Jan 2021 22:29:50 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id C86807FC6; Sun, 10 Jan 2021 22:29:50 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 10AMTomY087575; Sun, 10 Jan 2021 22:29:50 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 10AMToeD087574; Sun, 10 Jan 2021 22:29:50 GMT (envelope-from git) Date: Sun, 10 Jan 2021 22:29:50 GMT Message-Id: <202101102229.10AMToeD087574@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Toomas Soome Subject: git: 89632acb50f1 - main - loader: term_image_display() should test screen_buffer MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: tsoome X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 89632acb50f1a0bcc6ce82b9921f779cafaa9468 Auto-Submitted: auto-generated X-BeenThere: dev-commits-src-all@freebsd.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Commit messages for all branches of the src repository List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 10 Jan 2021 22:29:51 -0000 The branch main has been updated by tsoome: URL: https://cgit.FreeBSD.org/src/commit/?id=89632acb50f1a0bcc6ce82b9921f779cafaa9468 commit 89632acb50f1a0bcc6ce82b9921f779cafaa9468 Author: Toomas Soome AuthorDate: 2021-01-10 19:56:34 +0000 Commit: Toomas Soome CommitDate: 2021-01-10 19:59:52 +0000 loader: term_image_display() should test screen_buffer Make sure screen_buffer is not NULL. --- stand/efi/libefi/efi_console.c | 3 +++ stand/i386/libi386/vidconsole.c | 3 +++ 2 files changed, 6 insertions(+) diff --git a/stand/efi/libefi/efi_console.c b/stand/efi/libefi/efi_console.c index 22adcd3a00e2..6782cf5696a8 100644 --- a/stand/efi/libefi/efi_console.c +++ b/stand/efi/libefi/efi_console.c @@ -147,6 +147,9 @@ term_image_display(teken_gfx_t *state, const teken_rect_t *r) teken_pos_t p; int idx; + if (screen_buffer == NULL) + return; + for (p.tp_row = r->tr_begin.tp_row; p.tp_row < r->tr_end.tp_row; p.tp_row++) { for (p.tp_col = r->tr_begin.tp_col; diff --git a/stand/i386/libi386/vidconsole.c b/stand/i386/libi386/vidconsole.c index 47150b3dd09f..b42a476ef85e 100644 --- a/stand/i386/libi386/vidconsole.c +++ b/stand/i386/libi386/vidconsole.c @@ -109,6 +109,9 @@ term_image_display(teken_gfx_t *state, const teken_rect_t *r) teken_pos_t p; int idx; + if (screen_buffer == NULL) + return; + for (p.tp_row = r->tr_begin.tp_row; p.tp_row < r->tr_end.tp_row; p.tp_row++) { for (p.tp_col = r->tr_begin.tp_col;