Patch received from Daniel Beaudoin (Optel Vision) on 23/07/2012)

Fix for #44 - Placeholder at the last position of statement causing crash.