Leading off with "however" is a dead giveaway that Leo XII was not coming out in favor of free speech as your little snippet implied. Here is the rest of the paragraph:
23. We must now consider briefly liberty of speech, and liberty of the press. It is hardly necessary to say that there can be no such right as this, if it be not used in moderation, and if it pass beyond the bounds and end of all true liberty. For right is a moral power which -- as We have before said and must again and again repeat -- it is absurd to suppose that nature has accorded indifferently to truth and falsehood, to justice and injustice. Men have a right freely and prudently to propagate throughout the State what things soever are true and honorable, so that as many as possible may possess them; but lying opinions, than which no mental plague is greater, and vices which corrupt the heart and moral life should be diligently repressed by public authority, lest they insidiously work the ruin of the State.Clearly Pope Leo XIII was not quite ready to join the ACLU.The excesses of an unbridled intellect, which unfailingly end in the oppression of the untutored multitude, are no less rightly controlled by the authority of the law than are the injuries inflicted by violence upon the weak. And this all the more surely, because by far the greater part of the community is either absolutely unable, or able only with great difficulty, to escape from illusions and deceitful subtleties, especially such as flatter the passions. If unbridled license of speech and of writing be granted to all, nothing will remain sacred and inviolate; even the highest and truest mandates of natures, justly held to be the common and noblest heritage of the human race, will not be spared. Thus, truth being gradually obscured by darkness, pernicious and manifold error, as too often happens, will easily prevail. Thus, too, license will gain what liberty loses; for liberty will ever be more free and secure in proportion as license is kept in fuller restraint.
Nope, not the ACLU for Leo XIII. But on questions where neither divine Revelation nor the Church of Christ have pronounced sentence, free discussion may be given.