utent.c: fix a few bugs, and shrink a bit
utent.c: fix a few bugs, and shrink a bit

bug #1:
    static_fd = -1;
    close(static_fd);
DOH!

bug #2:
    if (utmp_fd == -1) {
        __setutent();
    }
    if (utmp_fd == -1) {
        return NULL;
    }
if utmp_fd == -1, we call _setutent().
if __setutent() opens a fd, utmp_fd (a parameter)
wouldn't change, the second check is bogus.
We need to use static_fd instead in second check.
Which makes clear that having utmp_fd parameter
is wrong. See the patch for a complete fix.

Shrink comes from simplifying fcntl(static_fd, F_SETFD, FD_CLOEXEC):

    text           data     bss     dec     hex filename
-    661              8     384    1053     41d libc/misc/utmp/utent.o
+    604              8     384     996     3e4 libc/misc/utmp/utent.o

Signed-off-by: Denys Vlasenko <42afb3a19136e88700e8b77002ea6a5a94c16782@googlemail.com>

hwoarang/uClibc,mephi42/uClibc,OpenInkpot-archive/iplinux-uclibc,ffainelli/uClibc,atgreen/uClibc-moxie,foss-for-synopsys-dwc-arc-processors/uClibc,foss-xtensa/uClibc,hjl-tools/uClibc,atgreen/uClibc-moxie,kraj/uClibc,ndmsystems/uClibc,waweber/uclibc-clang,kraj/uclibc-ng,waweber/uclibc-clang,mephi42/uClibc,OpenInkpot-archive/iplinux-uclibc,ysat0/uClibc,hwoarang/uClibc,mephi42/uClibc,hjl-tools/uClibc,kraj/uclibc-ng,skristiansson/uClibc-or1k,waweber/uclibc-clang,foss-xtensa/uClibc,m-labs/uclibc-lm32,hwoarang/uClibc,brgl/uclibc-ng,czankel/xtensa-uclibc,ffainelli/uClibc,OpenInkpot-archive/iplinux-uclibc,kraj/uClibc,m-labs/uclibc-lm32,hjl-tools/uClibc,gittup/uClibc,foss-for-synopsys-dwc-arc-processors/uClibc,atgreen/uClibc-moxie,kraj/uclibc-ng,groundwater/uClibc,m-labs/uclibc-lm32,czankel/xtensa-uclibc,skristiansson/uClibc-or1k,majek/uclibc-vx32,ysat0/uClibc,czankel/xtensa-uclibc,groundwater/uClibc,ddcc/klee-uclibc-0.9.33.2,groundwater/uClibc,gittup/uClibc,brgl/uclibc-ng,ffainelli/uClibc,wbx-github/uclibc-ng,ddcc/klee-uclibc-0.9.33.2,m-labs/uclibc-lm32,wbx-github/uclibc-ng,foss-xtensa/uClibc,foss-xtensa/uClibc,groundwater/uClibc,skristiansson/uClibc-or1k,kraj/uclibc-ng,waweber/uclibc-clang,ffainelli/uClibc,foss-for-synopsys-dwc-arc-processors/uClibc,OpenInkpot-archive/iplinux-uclibc,foss-for-synopsys-dwc-arc-processors/uClibc,ndmsystems/uClibc,ysat0/uClibc,ddcc/klee-uclibc-0.9.33.2,majek/uclibc-vx32,hwoarang/uClibc,czankel/xtensa-uclibc,ddcc/klee-uclibc-0.9.33.2,gittup/uClibc,ffainelli/uClibc,ndmsystems/uClibc,atgreen/uClibc-moxie,skristiansson/uClibc-or1k,hjl-tools/uClibc,wbx-github/uclibc-ng,brgl/uclibc-ng,mephi42/uClibc,hjl-tools/uClibc,ysat0/uClibc,majek/uclibc-vx32,brgl/uclibc-ng,gittup/uClibc,ndmsystems/uClibc,kraj/uClibc,wbx-github/uclibc-ng,kraj/uClibc,groundwater/uClibc,majek/uclibc-vx32