[arm-gnu] Bug fix for linux/uio.h (arm-2009q3 lite)
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[arm-gnu] Bug fix for linux/uio.h (arm-2009q3 lite)



I found a bug in the linux/uio.h distributed with the arm-2009q3 lite.

None of the header files included defines size_t

--- beginning of patch ---

Index: csl/arm-2009q3/arm-none-linux-gnueabi/libc/usr/include/linux/uio.h
===================================================================
--- csl.orig/arm-2009q3/arm-none-linux-gnueabi/libc/usr/include/linux/uio.h
+++ csl/arm-2009q3/arm-none-linux-gnueabi/libc/usr/include/linux/uio.h
@@ -34,16 +34,16 @@ struct iovec
  * segment lengths have been validated.  Because the individual lengths can
  * overflow a size_t when added together.
  */
-static __inline__ size_t iov_length(const struct iovec *iov, unsigned
long nr_segs)
+static __inline__ __kernel_size_t iov_length(const struct iovec *iov,
unsigned long nr_segs)
 {
     unsigned long seg;
-    size_t ret = 0;
+    __kernel_size_t ret = 0;
 
     for (seg = 0; seg < nr_segs; seg++)
         ret += iov[seg].iov_len;
     return ret;
 }
 
-unsigned long iov_shorten(struct iovec *iov, unsigned long nr_segs,
size_t to);
+unsigned long iov_shorten(struct iovec *iov, unsigned long nr_segs,
__kernel_size_t to);
 
 #endif

--- end of patch ---

Regards

Mira Kes