Re: [Linux-ia64] Re: memcpy failure

Christian Cotte-Barrot
2002-11-15T13:51:36Z

Matthew Wilcox wrote:
>
> On Fri, Nov 15, 2002 at 11:32:10AM +0100, Christian Cotte-Barrot wrote:
> > On bad return from memcpy the concerned device driver loggs warning
> > in /var/log/messages and the system administrator may have some doubt
> > about the good working of the device.
>
> _what_ bad return from memcpy?! memcpy returns the pointer that was
> passed to it. What are you going to check for?
>

Simply, bad return is whatever is not equal to the dest pointer:
if ((memcpy(rptr, ch->rxptr + tail, dataToRead)) != rptr)
...