📜 ⬆️ ⬇️

The trial between Google and Oracle: analyzes the origin of several lines of code

Many people know that the imminent possible scandal between the major players in the IT market of Google and Oracle, the underlying cause of which was the popular Android platform, resulted in a lawsuit between corporations, which began on Monday 16 April. The essence of the claims of Oracle is that the company, having bought Sun Microsystems in 2009, acquired the copyright on the Java programming language and now the Internet giant is illegally using Java technology in Android, thus violating Oracle patents.

Without going into details of the actual legal issues of patent law, it seems curious to follow the logic of Oracle's lawyers in their intention to prove that Google did not start from scratch in Android, and the source code of the system, at least, contains direct inserts directly from Java source code. In total, if noted for the sake of interest, Oracle accuses Google of copying 103,400 lines of Java code (a detailed description of the claim can be found in this pdf document)

So, after the initial statement by Oracle attorneys about deliberately abandoning patent royalties in favor of the legal owner of the technology, the consideration of the issue became more specific. Joshua Bloch was invited to the court, who currently works at Google and whose position in the corporation is designated as Chief Java Architect at Google (and it’s worth noting that Bloch worked for eight years at Sun before moving to Internet giant).

The source code for the array.java file contains the rangeCheck method:
/** 789 * Checks that {@code fromIndex} and {@code toIndex} are in 790 * the range and throws an appropriate exception, if they aren't. 791 */ 792 private static void rangeCheck(int length, int fromIndex, int toIndex) { 793 if (fromIndex > toIndex) { 794 throw new IllegalArgumentException( 795 "fromIndex(" + fromIndex + ") > toIndex(" + toIndex + ")"); 796 } 797 if (fromIndex < 0) { 798 throw new ArrayIndexOutOfBoundsException(fromIndex); 799 } 800 if (toIndex > length) { 801 throw new ArrayIndexOutOfBoundsException(toIndex); 802 } 803 } 

')
During the trial, Bloch confirmed that he was the author of this program code, which he wrote in 1997. According to the documents provided, Sun licensed the code in 2004 — in other words, even before it became Oracle’s property.

The same lines of code contain the TimSort.java and ComparableTimSort.java files included in Android, whose own authorship in 2007 was also confirmed by Bloch. When he was asked if he had copied them from Array.java code, at first, Bloch simply answered that he did not remember. When he was hinted that, in his own words, during a trial last year on a similar issue, he replied in the sense that the same meaning of the code and the same name suggests that it probably is did (“the same order is a strong indicator that I did”), it is now unclear when he was closer to the truth and what, in fact, can be concluded on this issue, the lawyers said, stressing Google's somewhat slurred position on this issue.

Thus, the court proceedings are proceeding at a very high level when the authorship of even small portions of the program code is analyzed, which, however, is not uncommon for this kind of cases.

For the sake of justice, it is worth noting that at the end of his speech, Bloch noticed the following: “If I did this, then it was a mistake, and I am very sorry that I did it.” In Android 4.0, the controversial rangeCheck method is missing.

[ Source ]

Source: https://habr.com/ru/post/142499/


All Articles