Still a bug to handle space chars in decode - fixed