MADRID, SPAIN - SEPTEMBER 12: Fernando Torres (L) of Atletico de Madrid competes for the ball with Javier Alejandro Mascherano (R) of FC Barcelona during the La Liga match between Club Atletico de Madrid and FC Barcelona at Vicente Calderon Stadium on September 12, 2015 in Madrid, Spain. (Photo by Gonzalo Arroyo Moreno/Getty Images)

Barcelona midfielder Javier Mascherano has been handed 12-month prison sentence for tax evasion, however, he won't have to spend a day behind bars thanks to a strange Spanish rule.

Macherano was handed two separate sentences, of four months and eight months, however, he has fallen under a bizarre rule that allows him to escape prison time.

In Spain a person given a two year or less prison sentence does not have to go to jail if he or she was convicted of a non-violent crime.

Mascherano has instead had to repay his €1.6 million tax debt for offences dating back to 2011 and 2012 and pay a fine of €816,000 on top of the repaid debts.