diff --exclude-from=/home/dang/bin/scripts/diffrc -up -ruN gcalctool-5.8.25.orig/gcalctool/ce_tokeniser.l gcalctool-5.8.25/gcalctool/ce_tokeniser.l --- gcalctool-5.8.25.orig/gcalctool/ce_tokeniser.l 2005-12-19 10:46:57.000000000 -0500 +++ gcalctool-5.8.25/gcalctool/ce_tokeniser.l 2007-02-10 20:36:06.000000000 -0500 @@ -102,7 +102,7 @@ MPstr_to_num(yytext, v->base, celval.int return tINUMBER; } -{DIGIT}*{DECIMAL}{DIGIT}+ { +{HEX}*{DECIMAL}{HEX}+ { if (strlen(yytext) > 40) parser_state.error = -PARSER_ERR_TOO_LONG_NUMBER; check_numbase(yytext); MPstr_to_num(yytext, v->base, celval.int_t); diff --exclude-from=/home/dang/bin/scripts/diffrc -up -ruN gcalctool-5.8.25.orig/gcalctool/functions.c gcalctool-5.8.25/gcalctool/functions.c --- gcalctool-5.8.25.orig/gcalctool/functions.c 2006-11-02 13:02:44.000000000 -0500 +++ gcalctool-5.8.25/gcalctool/functions.c 2007-02-10 20:36:06.000000000 -0500 @@ -1447,8 +1447,8 @@ do_shift() /* Perform bitwise shift int n = char_val(e->button.value[0]); int ret = usable_num(MPval); - if (ret) { - update_statusbar(_("No sane value to store"), + if (ret || !is_integer(MPval)) { + update_statusbar(_("No sane value to do bitwise shift"), "gtk-dialog-error"); return; }