MONWHEA JENG <[EMAIL PROTECTED]> wrote: > I think there is a bug in expr. When I type > "expr 2 * 3", I get "expr: syntax error." The man page for expr > leads me to think that I should get 6.
Thanks, but that's not a bug. Your shell is expanding the `*' to a list of all (or most) of the files in your current directory, so it's as if you'd typed e.g., expr 2 file.txt bar.txt foo.c ... 3 That's obviously not what you intended. Instead, you should `escape' the asterisk: e.g., expr 2 '*' 3 or expr 2 \* 3 FYI, if you have a similar problem in the future, I suggest you try to see if someone has reported or discussed one like it. One way to do that is to search using Google.com. In this case, I'd start by searching for the diagnostic, e.g., (put double quotes around the exact error message): "expr: syntax error" but that was too general and didn't find anything promising in the first page of matches. So I added a word: "expr: syntax error" multiply and with that, the first three matches answer your question. _______________________________________________ Bug-sh-utils mailing list [EMAIL PROTECTED] http://mail.gnu.org/mailman/listinfo/bug-sh-utils
