Trying to get definitive answers is tough, or at least I'm finding it tough, but Italian copyright law is different from that of other countries, as showtunetrivia notes below. This may have changed since POTO but that doesn't matter. I'm pretty sure that at the time POTO came along, much of Puccini was still under copyright in Italy and perhaps in other countries. It may be that the Puccini estate and Ricordi (if Ricordi was also involved) would have lost if it it had come to trial, but it's said that ALW settled out of court, perhaps just wanting to avoid adverse publicity.
I don't really know what happened, but the info I'm finding suggests that the Puccini estate and Ricordi might well have had at least enough of a case that ALW and his lawyers felt compelled to settle.