From 7ff876303b73e0231f98f8e79556ea6b727e414f Mon Sep 17 00:00:00 2001 From: Mike Baker Date: Sun, 12 Mar 2006 04:53:17 +0000 Subject: [PATCH] fix bitops on 32bit ints SVN-Revision: 3348 --- openwrt/package/busybox/patches/220-awk_bitops.patch | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/openwrt/package/busybox/patches/220-awk_bitops.patch b/openwrt/package/busybox/patches/220-awk_bitops.patch index 4eddb19b56..2b85729135 100644 --- a/openwrt/package/busybox/patches/220-awk_bitops.patch +++ b/openwrt/package/busybox/patches/220-awk_bitops.patch @@ -35,27 +35,27 @@ + break; + + case B_an: -+ setvar_i(res, (unsigned long)getvar_i(av[0]) & (unsigned long)getvar_i(av[1])); ++ setvar_i(res, (long)getvar_i(av[0]) & (long)getvar_i(av[1])); + break; + + case B_co: -+ setvar_i(res, ~(unsigned long)getvar_i(av[0])); ++ setvar_i(res, ~(long)getvar_i(av[0])); + break; + + case B_ls: -+ setvar_i(res, (unsigned long)getvar_i(av[0]) << (unsigned long)getvar_i(av[1])); ++ setvar_i(res, (long)getvar_i(av[0]) << (long)getvar_i(av[1])); + break; + + case B_or: -+ setvar_i(res, (unsigned long)getvar_i(av[0]) | (unsigned long)getvar_i(av[1])); ++ setvar_i(res, (long)getvar_i(av[0]) | (long)getvar_i(av[1])); + break; + + case B_rs: -+ setvar_i(res, (unsigned long)getvar_i(av[0]) >> (unsigned long)getvar_i(av[1])); ++ setvar_i(res, (long)((unsigned long)getvar_i(av[0]) >> (unsigned long)getvar_i(av[1]))); + break; + + case B_xo: -+ setvar_i(res, (unsigned long)getvar_i(av[0]) ^ (unsigned long)getvar_i(av[1])); ++ setvar_i(res, (long)getvar_i(av[0]) ^ (long)getvar_i(av[1])); break; case B_lo: -- 2.30.2