[prev in list] [next in list] [prev in thread] [next in thread] 

List:       haiku-commits
Subject:    [haiku-commits] haiku: hrev54607 - src/servers/app
From:       Adrien Destugues <pulkomandy () gmail ! com>
Date:       2020-09-29 18:02:29
Message-ID: 20200929180229.8C219245E1 () turing ! freelists ! org
[Download RAW message or body]

hrev54607 adds 1 changeset to branch 'master'
old head: 7ace34a6ba91a79b1f73fe5ca164dd2ca8128e23
new head: 0d87f2555a39e4f0f6c1faa0e3b4044bd3ab6599
overview: https://git.haiku-os.org/haiku/log/?qt=range&q=0d87f2555a39+%5E7ace34a6ba91

----------------------------------------------------------------------------

0d87f2555a39: app_server: missing null pointer check.
  
  Should fix #16551.

                             [ Adrien Destugues <pulkomandy@pulkomandy.tk> ]

----------------------------------------------------------------------------

Revision:    hrev54607
Commit:      0d87f2555a39e4f0f6c1faa0e3b4044bd3ab6599
URL:         https://git.haiku-os.org/haiku/commit/?id=0d87f2555a39
Author:      Adrien Destugues <pulkomandy@pulkomandy.tk>
Date:        Tue Sep 29 18:01:03 2020 UTC

Ticket:      https://dev.haiku-os.org/ticket/16551

----------------------------------------------------------------------------

1 file changed, 4 insertions(+)
src/servers/app/ScreenConfigurations.cpp | 4 ++++

----------------------------------------------------------------------------

diff --git a/src/servers/app/ScreenConfigurations.cpp b/src/servers/app/ScreenConfigurations.cpp
index 386c8cd216..36656d532d 100644
--- a/src/servers/app/ScreenConfigurations.cpp
+++ b/src/servers/app/ScreenConfigurations.cpp
@@ -157,6 +157,10 @@ float
 ScreenConfigurations::Brightness(int32 id)
 {
 	screen_configuration* configuration = fConfigurations.ItemAt(0);
+
+	if (configuration == NULL)
+		return -1;
+
 	return configuration->brightness;
 }
 


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic