Fixed memory management in parser

parser no longer carries old data from previous commands, this also
happens to fix the problem we were having with add