[Finsh] Fix '0' token issue.

This commit is contained in:
Bernard Xiong 2014-05-05 13:51:26 +08:00
parent 075f79708a
commit cde9139bc5
1 changed files with 4 additions and 1 deletions

View File

@ -521,8 +521,11 @@ static void token_proc_number(struct finsh_token* self)
} }
else else
{ {
/* Not a valid number */
token_prev_char(self); token_prev_char(self);
/* made as 0 value */
self->value.int_value = 0;
self->current_token = finsh_token_type_value_int;
return; return;
} }