Annotation of libaitwww/example/test_base64.c, revision 1.1.2.1

1.1.2.1 ! misho       1: #include <stdio.h>
        !             2: #include <unistd.h>
        !             3: #include <fcntl.h>
        !             4: #include <aitwww.h>
        !             5: 
        !             6: 
        !             7: int
        !             8: main(int argc, char **argv)
        !             9: {
        !            10:        int fd = STDOUT_FILENO;
        !            11: 
        !            12:        if (argc > 1) {
        !            13:                fd = open(argv[1], O_RDONLY);
        !            14:                if (fd == -1) {
        !            15:                        perror("open");
        !            16:                        return 1;
        !            17:                }
        !            18:        }
        !            19: 
        !            20:        if (fd > 2)
        !            21:                close(fd);
        !            22:        return 0;
        !            23: }

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>