lineedit: do not hang on error, but return error indicator.
[oweals/busybox.git] / coreutils / expr.c
index 54c2ee1655510614319d1f4b49ac4b80c683065e..04d783f2b58fc21d050fdf9475abb8ef3e81a8f2 100644 (file)
@@ -11,7 +11,7 @@
  *  - reduced 464 bytes.
  *  - 64 math support
  *
- * Licensed under GPLv2 or later, see file LICENSE in this tarball for details.
+ * Licensed under GPLv2 or later, see file LICENSE in this source tree.
  */
 
 /* This program evaluates expressions.  Each token (operator, operand,
@@ -63,7 +63,7 @@ typedef struct valinfo VALUE;
 /* The arguments given to the program, minus the program name.  */
 struct globals {
        char **args;
-};
+} FIX_ALIASING;
 #define G (*(struct globals*)&bb_common_bufsiz1)
 
 /* forward declarations */
@@ -214,9 +214,9 @@ static arith_t arithmetic_common(VALUE *l, VALUE *r, int op)
 
 static VALUE *docolon(VALUE *sv, VALUE *pv)
 {
+       enum { NMATCH = 2 };
        VALUE *v;
        regex_t re_buffer;
-       const int NMATCH = 2;
        regmatch_t re_regs[NMATCH];
 
        tostring(sv);
@@ -341,7 +341,6 @@ static VALUE *eval6(void)
                freev(i2);
        }
        return v;
-
 }
 
 /* Handle : operator (pattern matching).