P
P
PetrSidorov2017-05-26 14:21:01
JavaScript
PetrSidorov, 2017-05-26 14:21:01

Accidentally used a GNU GPL component in a non-free program. What to do?

We, the developers of the program, accidentally used a GPL-licensed component in it.
The client bought the program and demanded the source code.
What to do in this case?
Open source code is not an option, because the program code is our work, and the component contains a maximum of 0.1% of the total code. If they had known, they would not have used this component, but it so happened that they accidentally used and sold the program to a client.
What should be done in this case? Is it enough to cut these GPL-licensed components from the program or do I need to return the money to the client?

Answer the question

In order to leave comments, you need to log in

5 answer(s)
S
SagePtr, 2018-08-30
@rovercar

Something like this (as a one-liner):

const f = (a, sum) => a.reduce((r, x, i) => r.concat(a.slice(i+1).filter(y => x + y == sum).map(y => [x, y])), [])
But for large amounts of data, this is unlikely to be effective, most likely, the most common solution with two nested loops will work faster and less memory-intensive than chasing an array through a slice / filter / map in a loop. In the forehead it's something like this:
const f = (a, sum) => {
  const l = a.length;
  let r = [];
  for (let i = 0; i < l-1; i++)
    for (let j = i+1; j < l; j++)
      if (a[i] + a[j] == sum)
        r.push([a[i], a[j]]);
  return r;
}

S
Sergey Novikov, 2017-05-26
@BOOMER_74

If the client ordered this product (development) and you have an agreement under which you are obliged to provide the source code, then he has every right to demand it. If the contract is simply for the purchase of a product (it's your product and you give the customer the right to use it), then such claims are unreasonable. The license has nothing to do with it.
However, if I require you (the author of the component; actually anyone) to open source precisely because it uses a GPL-licensed component (you did not specify the license version, but this is not important), then either rewrite , or open.

Z
Zr, 2017-05-26
@Zr

> We, the developers of a [nonfree] program, accidentally used a [GNU] GPL component in it.
> The client bought the program and demanded the source code.
> What to do in this case?
Well, for starters:
If your illegally used program under the GNU GPL has one owner (or at least just a countable number) - contact him (s) and ask him to sell you a copyleft exception [0].
[0] https://www.gnu.org/philosophy/selling-exceptions.html

A
airamkad, 2017-06-09
@airamkad

If it's an external library, you don't need to give anything away.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question