Added protection against incomplete commands