File opie-2.4_array-subscript.patch of Package opie

--- libopie/btoe.c
+++ libopie/btoe.c
@@ -2258,8 +2258,8 @@
   unsigned char cr;
 
   cl = s[start / 8];
-  cc = s[start / 8 + 1];
-  cr = s[start / 8 + 2];
+  cc = start % 8 + length > 8 ? s[start / 8 + 1] : 0;
+  cr = start % 8 + length > 16 ? s[start / 8 + 2] : 0;
   x = ((UINT4) (cl << 8 | cc) << 8 | cr);
   x = x >> (24 - (length + (start % 8)));
   x = (x & (0xffff >> (16 - length)));
openSUSE Build Service is sponsored by