zmq_stopwatch_stop: Don't return EFAULT

Function returning unsigned long int cannot return (-1)
This commit is contained in:
Martin Lucina 2010-08-25 09:50:45 +02:00
parent 2b2accb8bf
commit b66dd7afd2

View File

@ -765,10 +765,6 @@ unsigned long zmq_stopwatch_stop (void *watch_)
{
uint64_t end = now ();
uint64_t start = *(uint64_t*) watch_;
if (!watch_) {
errno = EFAULT;
return -1;
}
free (watch_);
return (unsigned long) (end - start);
}