GNU bug report logs - #46451
[PATCH 0/2] OpenJDK: Fix NullPointerException when accessing fonts

Previous Next

Package: guix-patches;

Reported by: Björn Höfling <bjoern.hoefling <at> bjoernhoefling.de>

Date: Thu, 11 Feb 2021 23:15:02 UTC

Severity: normal

Tags: patch

Done: Leo Prikler <leo.prikler <at> student.tugraz.at>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: help-debbugs <at> gnu.org (GNU bug Tracking System)
To: Leo Prikler <leo.prikler <at> student.tugraz.at>
Cc: tracker <at> debbugs.gnu.org
Subject: bug#46451: closed ([PATCH 0/2] OpenJDK: Fix NullPointerException
 when accessing fonts)
Date: Fri, 12 Feb 2021 10:53:02 +0000
[Message part 1 (text/plain, inline)]
Your message dated Fri, 12 Feb 2021 11:52:50 +0100
with message-id <7cfa2fd2c86b16bee0eeb5e9d9de658e895292ec.camel <at> student.tugraz.at>
and subject line Re: [PATCH 0/2] OpenJDK: Fix NullPointerException when accessing fonts
has caused the debbugs.gnu.org bug report #46451,
regarding [PATCH 0/2] OpenJDK: Fix NullPointerException when accessing fonts
to be marked as done.

(If you believe you have received this mail in error, please contact
help-debbugs <at> gnu.org.)


-- 
46451: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=46451
GNU Bug Tracking System
Contact help-debbugs <at> gnu.org with problems
[Message part 2 (message/rfc822, inline)]
From: Björn Höfling <bjoern.hoefling <at> bjoernhoefling.de>
To: <guix-patches <at> gnu.org>
Subject: [PATCH 0/2] OpenJDK: Fix NullPointerException when accessing fonts
Date: Fri, 12 Feb 2021 00:14:05 +0100
[Message part 3 (text/plain, inline)]
These two patches fix a NullPointerException in the OpenJDK packages.

The patches apply only to OpenJDK9 and OpenJDK11, but with inheritence
all OpenJDKx with x\in[9..14] are covered.

Here is the bug report:

https://debbugs.gnu.org/cgi/bugreport.cgi?bug=41177

In order to test it you can use the following Main.java:

~~~~~~
import java.awt.*;

public class Main {

    public static void main(String[] args)
    {
        String fonts[] =
            GraphicsEnvironment.getLocalGraphicsEnvironment().getAvailableFontFamilyNames();

        for ( int i = 0; i < fonts.length; i++ )
	    {
		System.out.println(fonts[i]);
	    }
    }
}

~~~~~~~~
Compile: javac Main.java
Run: java -cp . Main

It should print a list of the available fonts.


Björn


Björn Höfling (2):
  gnu: openjdk <at> 9 : Add phase to hardcode libraries.
  gnu: openjdk11: Add phase to hardcode libraries.

 gnu/packages/java.scm | 56 ++++++++++++++++++++++++++++++++++++++++++-
 1 file changed, 55 insertions(+), 1 deletion(-)

-- 
2.27.0

[Message part 4 (application/pgp-signature, inline)]
[Message part 5 (message/rfc822, inline)]
From: Leo Prikler <leo.prikler <at> student.tugraz.at>
To: Björn Höfling <bjoern.hoefling <at> bjoernhoefling.de>
Cc: 46451-done <at> debbugs.gnu.org, 41177-done <at> debbugs.gnu.org
Subject: Re: [PATCH 0/2] OpenJDK: Fix NullPointerException when accessing fonts
Date: Fri, 12 Feb 2021 11:52:50 +0100
Hi Björn

Am Freitag, den 12.02.2021, 00:14 +0100 schrieb Björn Höfling:
> These two patches fix a NullPointerException in the OpenJDK packages.
> 
> The patches apply only to OpenJDK9 and OpenJDK11, but with
> inheritence
> all OpenJDKx with x\in[9..14] are covered.
> 
> Here is the bug report:
> 
> https://debbugs.gnu.org/cgi/bugreport.cgi?bug=41177
> 
> In order to test it you can use the following Main.java:
> 
> ~~~~~~
> import java.awt.*;
> 
> public class Main {
> 
>     public static void main(String[] args)
>     {
>         String fonts[] =
>             GraphicsEnvironment.getLocalGraphicsEnvironment().getAvai
> lableFontFamilyNames();
> 
>         for ( int i = 0; i < fonts.length; i++ )
> 	    {
> 		System.out.println(fonts[i]);
> 	    }
>     }
> }
> 
> ~~~~~~~~
> Compile: javac Main.java
> Run: java -cp . Main
> 
> It should print a list of the available fonts.
Indeed, that it does.  At least for 9 and 11, which I've invoked
directly from their store paths.

I've pushed your patches with small changes to the commit messages and
followed up with an indentation fix.

Regards,
Leo



This bug report was last modified 4 years and 98 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.