os: remove unneeded errno assignment
authorPekka Paalanen <ppaalanen@gmail.com>
Mon, 23 Apr 2012 08:37:40 +0000 (11:37 +0300)
committerPekka Paalanen <ppaalanen@gmail.com>
Wed, 25 Apr 2012 06:32:57 +0000 (09:32 +0300)
If socket() fails, it will return failure code. No need to reset errno
beforehand.

Signed-off-by: Pekka Paalanen <ppaalanen@gmail.com>
src/wayland-os.c

index 5ff4391..8f75976 100644 (file)
@@ -56,7 +56,6 @@ wl_os_socket_cloexec(int domain, int type, int protocol)
        int fd;
 
 #ifdef SOCK_CLOEXEC
-       errno = 0;
        fd = socket(domain, type | SOCK_CLOEXEC, protocol);
        if (fd >= 0)
                return fd;