Leon bent in a free-kick from 25 yards to give Simon Davey’s side a half-time lead before former North End hero Macken buried a contentious penalty.
Captain Stephen Foster then scored a crazy own goal to test the visitors’ nerves but they held on for the three points to move four points clear of the drop.
Despite seeing Alan Irvine’s side dominate the majority of the game Barnsley twice hit Preston on the break to ensure that the hosts’ own relegation concerns will linger on.
Leon (33) curled a free-kick into the top corner for the opener and when Jamal Campbell-Ryce was felled by Billy Jones, Macken scored the penalty.
But Foster headed over his own keeper Lee Steele to make it a nervous finish.