IANAL, so I imagine since you’re concerned you should really talk to one. Having said that, I don’t see an issue with this code. The original JDK code has a
different method signature (arrays vs StringBuilder), which makes the code literally quite different. The only literal copies are these 3 lines:
if (Character.isBmpCodePoint(codePoint)) {
} else
if (Character.isValidCodePoint(codePoint)) {
throw
new IllegalArgumentException("Invalid codepoint
" + codePoint);
Taking each line in isolation, it’s inconceivable that they would cause an issue, because there is no other way to invoke those methods on Character. If Oracle
objects to someone putting Character.isXXXCodePoint() in an if-statement, I’d be curious to understand why they’d provide the method in the first place. And the exception is common place.
So that only leaves the overall structure (the if-else-elseThrow construct). The structure would be considered ordinary to anyone familiar with code points.
Again, just my take on this (and I don’t speak for anyone but myself). I’d be curious to hear from the Eclipse IP team (de minimis and all that).
Thanks
Moh
From: incubation-bounces@xxxxxxxxxxx [mailto:incubation-bounces@xxxxxxxxxxx]
On Behalf Of Jeen Broekstra
Sent: Thursday, September 15, 2016 6:07 PM
To: incubation@xxxxxxxxxxx
Subject: [incubation] reusing (modified) GPL code: at which length does this become a problem?
I have a contributor on our project (RDF4J) who has submitted a patch which includes a modified copy of a method taken from the OpenJDK source code. It mentions this fact in the code comments.
The method in question is quite basic (it's a conversion from codepoint integers to chars, all in all about 15 lines of code). The modification of the original is an optimization for our specific purposes (avoiding creation of a lot of internal string arrays).
The OpenJDK source code is licensed under GPL, and as I understand its terms, inclusion of a (modified) copy of GPL code would require us to distribute the entire project under GPL (which is clearly not what we want).
So the question is: at which point does such a "modified copy" of GPL code become significant enough that it no longer counts as simple 'citation'? Are there allowances in the number of lines and/or the fundamental simplicity of the algorithm that would
enable us to accept this patch?
The contribution in question (including discussion) can be seen here:
https://github.com/eclipse/rdf4j/pull/571
Regards,
Jeen