// File: /workspace/github_c_makefile_star2_O0/hfiguiere[P]exifprobe/main.c
// Function: main
int
main(int argc,char **argv)
{
    char *file;
    char *name = CNULL;
    FILE *inptr;
    int status = -1;
    unsigned long max_offset = 0UL;
    unsigned long ifd_offset = 0UL;
    unsigned long dumplength = 0UL;
    struct fileheader *header = NULL;
    struct image_summary *summary_entry = NULL;
    unsigned long filesize = 0UL;
    int chpr = 0;


    Progname = *argv;

    /* Gather options from EXIFPROBE_OPTIONS first                    */
    env_options();

    /* Now the command line                                           */
    argv += process_options(argc,argv);

    while((file = *argv++))
    {
        inptr = fopen(file,"rb");
        if(inptr == FNULL)
        {
            fprintf(stderr,"%s: failed to open file %s\n",Progname,file);
            why(stderr);
            max_offset = 0L;
        }
        else
        {
            PUSHCOLOR(BLACK);
            setfilename(file);  /* for '-n' option                    */
            filesize = get_filesize(inptr);

            if(Start_offset > filesize)
            {
                PUSHCOLOR(RED);
                print_filename();
                chpr += printf(" start offset %lu > filesize %lu\n",
                                            Start_offset,filesize);
                POPCOLOR();
                continue;
            }
            else if(Start_offset)
            {
                if(fseek(inptr,Start_offset,SEEK_SET) == -1)
                {
                    fprintf(stderr,"%s: FAILED to seek to start offset %lu\n",
                                                        Progname,Start_offset);
                    why(stdout);
                    continue;
                }
                printf("# Start at %ld\n",ftell(inptr));
            }

            print_filename();   /* for '-n' option                    */
            if((LIST_MODE))
                chpr += printf("FileName = %s",file);
            else
                chpr += printf("File Name = %s",file);
            chpr = newline(chpr);

            header = read_imageheader(inptr,Start_offset);
            if(ferror(inptr))
                continue;
            print_filename();
            if((LIST_MODE))
                chpr += printf("FileType = ");
            else
                chpr += printf("File Type = ");
            status = print_filetype(header->probe_magic,header->file_marker);
            chpr = newline(chpr);

            print_filename();
            if((LIST_MODE))
                chpr += printf("FileSize = %lu",filesize);
            else
                chpr += printf("File Size = %lu",filesize);
            chpr = newline(chpr);

            if(status == 0)
            {
                switch(header->probe_magic)
                {
                    case ORF1_MAGIC:
                    case ORF2_MAGIC:
                    case RW2_MAGIC:
                    case TIFF_MAGIC:
                        ifd_offset = read_ulong(inptr,header->file_marker,HERE); 
                        if(ifd_offset > filesize)
                        {
                            hexdump(inptr,Start_offset,10,10,12,0,0);
                            chpr = newline(chpr);
                            if(Max_undefined > 0L)
                                dumplength = Max_undefined - 10;
                            else
                                dumplength = 60;
                            if(dumplength)
                            {
                                hexdump(inptr,Start_offset +  10,
                                            filesize - 10 - Start_offset,
                                                            dumplength,12,0,0);
                                chpr = newline(1);
                            }
                            status = -1;
                            break;
                        }
                        summary_entry = new_summary_entry(NULL,header->probe_magic,TIFF_IFD);
                        name = "TIFF";
                        switch(header->probe_magic)
                        {
                            case ORF1_MAGIC:
                                name = "ORF1";
                                break;
                            case ORF2_MAGIC:
                                name = "ORF2";
                                break;
                            case RW2_MAGIC:
                                name = "RW2";
                                break;
                            case TIFF_MAGIC:
                            default:
                                break;
                        }

                        if(PRINT_SECTION)
                        {
                            print_tag_address(SECTION,Start_offset,0,"@");
                            status = print_header(header,SECTION);
                            chpr += printf(" ifd offset = %#lx/%lu",ifd_offset,ifd_offset);
                            if(Start_offset)
                            {
                                chpr += printf(" (+ %lu = %#lx/%lu)",Start_offset,
                                                                Start_offset + ifd_offset,
                                                                Start_offset + ifd_offset);
                            }
                            chpr = newline(chpr);
                        }
                        max_offset = process_tiff_ifd(inptr,header->file_marker,
                                            ifd_offset,Start_offset,0L,summary_entry,name,
                                            TIFF_IFD,0,-1,0);
                        if(max_offset > 0L)
                            status = 0;
                        fflush(stdout);
                        break;
                    case JPEG_SOI:
                        summary_entry = new_summary_entry(NULL,FILEFMT_JPEG,IMGFMT_JPEG);
                        if(summary_entry)
                            summary_entry->subfiletype = PRIMARY_TYPE;
                        max_offset = process_jpeg_segments(inptr,Start_offset,JPEG_SOI,0L,summary_entry,
                                                                            "JPEG","@",0);
                        status = jpeg_status(0);
                        fflush(stdout);
                        break;
                    case PROBE_CIFFMAGIC:
                        summary_entry = new_summary_entry(NULL,FILEFMT_CIFF,IMGFMT_CRW);
                        if(PRINT_SECTION)
                        {
                            print_tag_address(SECTION,Start_offset,0,"@");
                            status = print_header(header,SECTION);
                        }
                        max_offset = process_ciff(inptr,header,Start_offset,0L,summary_entry,"CIFF",0,0);
                        if(max_offset > 0L)
                            status = 0;
                        fflush(stdout);
                        break;
                    case PROBE_JP2MAGIC:
                        summary_entry = new_summary_entry(NULL,FILEFMT_JP2,IMGFMT_JPEG2000);
                        if(PRINT_SECTION)
                        {
                            print_tag_address(SECTION,Start_offset,0,"@");
                            status = print_header(header,SECTION);
                        }
                        max_offset = process_jp2(inptr,Start_offset + 12L,summary_entry,"JP2",0L);
                        if(max_offset > 0L)
                            status = 0;
                        fflush(stdout);
                        break;
                    case PROBE_MRWMAGIC:
                        summary_entry = new_summary_entry(NULL,FILEFMT_MRW,IMGFMT_MRW);
                        if(PRINT_SECTION)
                        {
                            print_tag_address(SECTION,Start_offset,0,"@");
                            status = print_header(header,SECTION);
                        }
                        max_offset =
                            process_mrw(inptr,Start_offset + 8L,
                                    header->mrw_header.mrw_dataoffset,
                                    filesize - header->mrw_header.mrw_dataoffset,
                                    summary_entry,"MRW",0L);
                        if(max_offset > 0L)
                            status = 0;
                        fflush(stdout);
                        break;
                    case PROBE_RAFMAGIC:
                        summary_entry = new_summary_entry(NULL,FILEFMT_RAF,IMGFMT_RAF);
                        if(PRINT_SECTION)
                        {
                            print_tag_address(SECTION,Start_offset,0,"@");
                            status = print_raf_header(inptr,header,SECTION);
                        }
                        if(status == 0)
                        {
                            max_offset = process_raf(inptr,Start_offset + 60,summary_entry,"RAF",0L);
                            if(max_offset > 0L)
                                status = 0;
                        }
                        fflush(stdout);
                        break;
                    case PROBE_X3FMAGIC:
                        summary_entry = new_summary_entry(NULL,FILEFMT_X3F,IMGFMT_X3F);
                        if(PRINT_SECTION)
                        {
                            print_tag_address(SECTION,Start_offset,0,"@");
                            status = print_x3f_header(inptr,header,SECTION);
                        }
                        if(status == 0)
                        {
                            max_offset = process_x3f(inptr,header,Start_offset,summary_entry,
                                                                                "X3F",0,0);
                            if(max_offset > 0L)
                                status = 0;
                        }
                        break;
                    default:
                        status = -1;
                        break;
                }
                if(status == JPEG_EARLY_EOI)
                    chpr = newline(chpr);
                print_tag_address(SECTION,filesize - 1,0,"-");
                if(PRINT_SECTION)
                {
                    chpr += printf("END OF FILE");
                    if(status == JPEG_EARLY_EOI)
                    {
                        jpeg_status(status);
                        print_jpeg_status();
                    }
                }
                chpr = newline(chpr);
                /* Print a summary of image sections found            */
                print_summary(summary_entry);
            }
            else
            {
                /* Allow hex/ascii dump of unregcognized file         */
                /* formats. In fact, always dump a little bit.        */
                if(Max_undefined == DUMPALL)
                    dumplength = filesize;
                else if(Max_undefined > 0L)
                    dumplength = Max_undefined;
                else
                    dumplength = DEF_DUMPLENGTH;
                if(dumplength)
                {
                    hexdump(inptr,Start_offset,filesize,dumplength,16,0,0);
                    chpr = newline(chpr);
                }
            }
            print_fileformat(summary_entry);
            summary_entry = destroy_summary(summary_entry);
            chpr = newline(1);
            if(inptr && fclose(inptr))
            {
                fprintf(stderr,"%s: FAILED to close stream for file \"%s\"\n",Progname,file);
                why(stderr);
            }
        }
        clear_memory();     /* Make, Model, Software...               */
        chpr = newline(1);
    }
    if(PRINT_CAMERA_NAMES)
        print_camera_makes();
    return(status);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0xa0, %rsp
movl $0x0, -0x4(%rbp)
movl %edi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq $0x0, -0x20(%rbp)
movl $0xffffffff, -0x2c(%rbp) # imm = 0xFFFFFFFF
movq $0x0, -0x38(%rbp)
movq $0x0, -0x40(%rbp)
movq $0x0, -0x48(%rbp)
movq $0x0, -0x50(%rbp)
movq $0x0, -0x58(%rbp)
movq $0x0, -0x60(%rbp)
movl $0x0, -0x64(%rbp)
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq %rax, 0x7502b(%rip)     # 0x78468
movb $0x0, %al
callq 0x28d30
movl -0x8(%rbp), %edi
movq -0x10(%rbp), %rsi
callq 0x28390
movl %eax, %ecx
movq -0x10(%rbp), %rax
movslq %ecx, %rcx
shlq $0x3, %rcx
addq %rcx, %rax
movq %rax, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq %rax, %rcx
addq $0x8, %rcx
movq %rcx, -0x10(%rbp)
movq (%rax), %rax
movq %rax, -0x18(%rbp)
cmpq $0x0, %rax
je 0x3f4a
movq -0x18(%rbp), %rdi
leaq 0x60b75(%rip), %rsi     # 0x64004
callq 0x3210
movq %rax, -0x28(%rbp)
cmpq $0x0, -0x28(%rbp)
jne 0x34de
movq 0x73b52(%rip), %rax     # 0x76ff8
movq (%rax), %rdi
movq 0x74fb8(%rip), %rdx     # 0x78468
movq -0x18(%rbp), %rcx
leaq 0x60b4c(%rip), %rsi     # 0x64007
movb $0x0, %al
callq 0x3170
movq 0x73b2f(%rip), %rax     # 0x76ff8
movq (%rax), %rdi
callq 0x20840
movq $0x0, -0x38(%rbp)
jmp 0x3f31
movq -0x18(%rbp), %rdi
callq 0x20a10
movq -0x28(%rbp), %rdi
callq 0x5530
movq %rax, -0x60(%rbp)
movq 0x74f2d(%rip), %rax     # 0x78428
cmpq -0x60(%rbp), %rax
jbe 0x352c
movb $0x0, %al
callq 0x20a30
movq 0x74f19(%rip), %rsi     # 0x78428
movq -0x60(%rbp), %rdx
leaq 0x60b09(%rip), %rdi     # 0x64023
movb $0x0, %al
callq 0x3110
addl -0x64(%rbp), %eax
movl %eax, -0x64(%rbp)
jmp 0x3464
cmpq $0x0, 0x74ef4(%rip)     # 0x78428
je 0x35a1
movq -0x28(%rbp), %rdi
movq 0x74ee7(%rip), %rsi     # 0x78428
xorl %edx, %edx
callq 0x3200
cmpl $-0x1, %eax
jne 0x3587
movq 0x73aa4(%rip), %rax     # 0x76ff8
movq (%rax), %rdi
movq 0x74f0a(%rip), %rdx     # 0x78468
movq 0x74ec3(%rip), %rcx     # 0x78428
leaq 0x60ad9(%rip), %rsi     # 0x64045
movb $0x0, %al
callq 0x3170
movq 0x73a4e(%rip), %rax     # 0x76fc8
movq (%rax), %rdi
callq 0x20840
jmp 0x3464
movq -0x28(%rbp), %rdi
callq 0x3180
movq %rax, %rsi
leaq 0x60ad3(%rip), %rdi     # 0x6406d
movb $0x0, %al
callq 0x3110
jmp 0x35a3
movb $0x0, %al
callq 0x20a30
movq 0x73bcf(%rip), %rax     # 0x77180
andq $0x1040000, %rax        # imm = 0x1040000
cmpq $0x0, %rax
jne 0x35d7
movq -0x18(%rbp), %rsi
leaq 0x60ab5(%rip), %rdi     # 0x6407d
movb $0x0, %al
callq 0x3110
addl -0x64(%rbp), %eax
movl %eax, -0x64(%rbp)
jmp 0x35ef
movq -0x18(%rbp), %rsi
leaq 0x60aa9(%rip), %rdi     # 0x6408b
movb $0x0, %al
callq 0x3110
addl -0x64(%rbp), %eax
movl %eax, -0x64(%rbp)
movl -0x64(%rbp), %edi
callq 0x1ef50
movl %eax, -0x64(%rbp)
movq -0x28(%rbp), %rdi
movq 0x74e23(%rip), %rsi     # 0x78428
callq 0x3f70
movq %rax, -0x50(%rbp)
movq -0x28(%rbp), %rdi
callq 0x30a0
cmpl $0x0, %eax
je 0x3621
jmp 0x3464
movb $0x0, %al
callq 0x20a30
movq 0x73b51(%rip), %rax     # 0x77180
andq $0x1040000, %rax        # imm = 0x1040000
cmpq $0x0, %rax
jne 0x3651
leaq 0x60a58(%rip), %rdi     # 0x6409a
movb $0x0, %al
callq 0x3110
addl -0x64(%rbp), %eax
movl %eax, -0x64(%rbp)
jmp 0x3665
leaq 0x60a4e(%rip), %rdi     # 0x640a6
movb $0x0, %al
callq 0x3110
addl -0x64(%rbp), %eax
movl %eax, -0x64(%rbp)
movq -0x50(%rbp), %rax
movq 0x8(%rax), %rdi
movq -0x50(%rbp), %rax
movzwl (%rax), %esi
callq 0x5b20
movl %eax, -0x2c(%rbp)
movl -0x64(%rbp), %edi
callq 0x1ef50
movl %eax, -0x64(%rbp)
movb $0x0, %al
callq 0x20a30
movq 0x73aeb(%rip), %rax     # 0x77180
andq $0x1040000, %rax        # imm = 0x1040000
cmpq $0x0, %rax
jne 0x36bb
movq -0x60(%rbp), %rsi
leaq 0x60a07(%rip), %rdi     # 0x640b3
movb $0x0, %al
callq 0x3110
addl -0x64(%rbp), %eax
movl %eax, -0x64(%rbp)
jmp 0x36d3
movq -0x60(%rbp), %rsi
leaq 0x609fc(%rip), %rdi     # 0x640c2
movb $0x0, %al
callq 0x3110
addl -0x64(%rbp), %eax
movl %eax, -0x64(%rbp)
movl -0x64(%rbp), %edi
callq 0x1ef50
movl %eax, -0x64(%rbp)
cmpl $0x0, -0x2c(%rbp)
jne 0x3e50
movq -0x50(%rbp), %rax
movq 0x8(%rax), %rax
movq %rax, -0x70(%rbp)
subq $0x1a, %rax
je 0x3a8e
jmp 0x3700
movq -0x70(%rbp), %rax
subq $0x2a, %rax
je 0x3795
jmp 0x3710
movq -0x70(%rbp), %rax
subq $0x55, %rax
je 0x3795
jmp 0x371c
movq -0x70(%rbp), %rax
subq $0x4655, %rax           # imm = 0x4655
je 0x3c88
jmp 0x372e
movq -0x70(%rbp), %rax
subq $0x4f52, %rax           # imm = 0x4F52
je 0x3795
jmp 0x373c
movq -0x70(%rbp), %rax
subq $0x5352, %rax           # imm = 0x5352
je 0x3795
jmp 0x374a
movq -0x70(%rbp), %rax
subq $0xffd8, %rax           # imm = 0xFFD8
je 0x3a09
jmp 0x375c
movq -0x70(%rbp), %rax
subq $0x4d524d, %rax         # imm = 0x4D524D
je 0x3bd4
jmp 0x376e
movq -0x70(%rbp), %rax
subq $0xd0a870a, %rax        # imm = 0xD0A870A
je 0x3b3a
jmp 0x3780
movq -0x70(%rbp), %rax
subq $0x62564f46, %rax       # imm = 0x62564F46
je 0x3d2e
jmp 0x3dc9
movq -0x28(%rbp), %rdi
movq -0x50(%rbp), %rax
movl $0xffffffff, %edx       # imm = 0xFFFFFFFF
movzwl (%rax), %esi
callq 0x4610
movq %rax, -0x40(%rbp)
movq -0x40(%rbp), %rax
cmpq -0x60(%rbp), %rax
jbe 0x3869
movq -0x28(%rbp), %rdi
movq 0x74c61(%rip), %rsi     # 0x78428
movl $0xa, %ecx
movl $0xc, %r8d
xorl %r9d, %r9d
movq %rcx, %rdx
movl $0x0, (%rsp)
callq 0x8aa0
movl -0x64(%rbp), %edi
callq 0x1ef50
movl %eax, -0x64(%rbp)
cmpq $0x0, 0x74c11(%rip)     # 0x78408
jbe 0x380a
movq 0x74c08(%rip), %rax     # 0x78408
subq $0xa, %rax
movq %rax, -0x48(%rbp)
jmp 0x3812
movq $0x3c, -0x48(%rbp)
cmpq $0x0, -0x48(%rbp)
je 0x385d
movq -0x28(%rbp), %rdi
movq 0x74c04(%rip), %rsi     # 0x78428
addq $0xa, %rsi
movq -0x60(%rbp), %rdx
subq $0xa, %rdx
subq 0x74bf1(%rip), %rdx     # 0x78428
movq -0x48(%rbp), %rcx
movl $0xc, %r8d
xorl %r9d, %r9d
movl $0x0, (%rsp)
callq 0x8aa0
movl $0x1, %edi
callq 0x1ef50
movl %eax, -0x64(%rbp)
movl $0xffffffff, -0x2c(%rbp) # imm = 0xFFFFFFFF
jmp 0x3dd0
movq -0x50(%rbp), %rax
movl 0x8(%rax), %esi
xorl %edx, %edx
movl %edx, %edi
callq 0x15420
movq %rax, -0x58(%rbp)
leaq 0x6412d(%rip), %rax     # 0x679b1
movq %rax, -0x20(%rbp)
movq -0x50(%rbp), %rax
movq 0x8(%rax), %rax
movq %rax, -0x78(%rbp)
subq $0x2a, %rax
je 0x38eb
jmp 0x389c
movq -0x78(%rbp), %rax
subq $0x55, %rax
je 0x38de
jmp 0x38a8
movq -0x78(%rbp), %rax
subq $0x4f52, %rax           # imm = 0x4F52
je 0x38c4
jmp 0x38b6
movq -0x78(%rbp), %rax
subq $0x5352, %rax           # imm = 0x5352
je 0x38d1
jmp 0x38ed
leaq 0x60807(%rip), %rax     # 0x640d2
movq %rax, -0x20(%rbp)
jmp 0x38ef
leaq 0x607ff(%rip), %rax     # 0x640d7
movq %rax, -0x20(%rbp)
jmp 0x38ef
leaq 0x64729(%rip), %rax     # 0x6800e
movq %rax, -0x20(%rbp)
jmp 0x38ef
jmp 0x38ed
jmp 0x38ef
movq 0x7388a(%rip), %rax     # 0x77180
andq $0x40000, %rax          # imm = 0x40000
cmpq $0x0, %rax
je 0x3993
movq 0x74b1b(%rip), %rsi     # 0x78428
movl $0x40000, %edi          # imm = 0x40000
xorl %edx, %edx
leaq 0x607c1(%rip), %rcx     # 0x640dc
callq 0x5ed0
movq -0x50(%rbp), %rdi
movl $0x40000, %esi          # imm = 0x40000
callq 0x55c0
movl %eax, -0x2c(%rbp)
movq -0x40(%rbp), %rsi
movq -0x40(%rbp), %rdx
leaq 0x6079e(%rip), %rdi     # 0x640de
movb $0x0, %al
callq 0x3110
addl -0x64(%rbp), %eax
movl %eax, -0x64(%rbp)
cmpq $0x0, 0x74ad3(%rip)     # 0x78428
je 0x3988
movq 0x74aca(%rip), %rsi     # 0x78428
movq 0x74ac3(%rip), %rdx     # 0x78428
addq -0x40(%rbp), %rdx
movq 0x74ab8(%rip), %rcx     # 0x78428
addq -0x40(%rbp), %rcx
leaq 0x63fda(%rip), %rdi     # 0x67955
movb $0x0, %al
callq 0x3110
addl -0x64(%rbp), %eax
movl %eax, -0x64(%rbp)
movl -0x64(%rbp), %edi
callq 0x1ef50
movl %eax, -0x64(%rbp)
movq -0x28(%rbp), %rdi
movq -0x50(%rbp), %rax
movw (%rax), %si
movq -0x40(%rbp), %rdx
movq 0x74a7f(%rip), %rcx     # 0x78428
movq -0x58(%rbp), %r9
movq -0x20(%rbp), %rax
xorl %r8d, %r8d
xorl %r10d, %r10d
movzwl %si, %esi
movq %rax, (%rsp)
movl $0x0, 0x8(%rsp)
movl $0x0, 0x10(%rsp)
movl $0xffffffff, 0x18(%rsp) # imm = 0xFFFFFFFF
movl $0x0, 0x20(%rsp)
callq 0x112e0
movq %rax, -0x38(%rbp)
cmpq $0x0, -0x38(%rbp)
jbe 0x39f5
movl $0x0, -0x2c(%rbp)
movq 0x735cc(%rip), %rax     # 0x76fc8
movq (%rax), %rdi
callq 0x31f0
jmp 0x3dd0
xorl %eax, %eax
movl %eax, %edi
movl $0xffd8, %edx           # imm = 0xFFD8
movl %edx, %esi
callq 0x15420
movq %rax, -0x58(%rbp)
cmpq $0x0, -0x58(%rbp)
je 0x3a32
movq -0x58(%rbp), %rax
movl $0x1, 0xc4(%rax)
movq -0x28(%rbp), %rdi
movq 0x749eb(%rip), %rsi     # 0x78428
movq -0x58(%rbp), %r8
movl $0xffd8, %edx           # imm = 0xFFD8
xorl %eax, %eax
movl %eax, %ecx
leaq 0x6464a(%rip), %r9      # 0x6809b
leaq 0x60684(%rip), %rax     # 0x640dc
xorl %r10d, %r10d
movq %rax, (%rsp)
movl $0x0, 0x8(%rsp)
callq 0x17470
movq %rax, -0x38(%rbp)
xorl %edi, %edi
callq 0x19930
movl %eax, -0x2c(%rbp)
movq 0x73547(%rip), %rax     # 0x76fc8
movq (%rax), %rdi
callq 0x31f0
jmp 0x3dd0
xorl %eax, %eax
movl %eax, %edi
movl $0x1a, %edx
movl %edx, %esi
callq 0x15420
movq %rax, -0x58(%rbp)
movq 0x736d7(%rip), %rax     # 0x77180
andq $0x40000, %rax          # imm = 0x40000
cmpq $0x0, %rax
je 0x3ae0
movq 0x7496c(%rip), %rsi     # 0x78428
movl $0x40000, %edi          # imm = 0x40000
xorl %edx, %edx
leaq 0x60612(%rip), %rcx     # 0x640dc
callq 0x5ed0
movq -0x50(%rbp), %rdi
movl $0x40000, %esi          # imm = 0x40000
callq 0x55c0
movl %eax, -0x2c(%rbp)
movq -0x28(%rbp), %rdi
movq -0x50(%rbp), %rsi
movq 0x74939(%rip), %rdx     # 0x78428
movq -0x58(%rbp), %r8
xorl %eax, %eax
movl %eax, %ecx
leaq 0x64469(%rip), %r9      # 0x67f67
xorl %eax, %eax
movl $0x0, (%rsp)
movl $0x0, 0x8(%rsp)
callq 0x29190
movq %rax, -0x38(%rbp)
cmpq $0x0, -0x38(%rbp)
jbe 0x3b26
movl $0x0, -0x2c(%rbp)
movq 0x7349b(%rip), %rax     # 0x76fc8
movq (%rax), %rdi
callq 0x31f0
jmp 0x3dd0
xorl %eax, %eax
movl %eax, %edi
movl $0xd0a870a, %edx        # imm = 0xD0A870A
movl %edx, %esi
callq 0x15420
movq %rax, -0x58(%rbp)
movq 0x7362b(%rip), %rax     # 0x77180
andq $0x40000, %rax          # imm = 0x40000
cmpq $0x0, %rax
je 0x3b8c
movq 0x748c0(%rip), %rsi     # 0x78428
movl $0x40000, %edi          # imm = 0x40000
xorl %edx, %edx
leaq 0x60566(%rip), %rcx     # 0x640dc
callq 0x5ed0
movq -0x50(%rbp), %rdi
movl $0x40000, %esi          # imm = 0x40000
callq 0x55c0
movl %eax, -0x2c(%rbp)
movq -0x28(%rbp), %rdi
movq 0x74891(%rip), %rsi     # 0x78428
addq $0xc, %rsi
movq -0x58(%rbp), %rdx
leaq 0x6054f(%rip), %rcx     # 0x640f5
xorl %r8d, %r8d
callq 0x2ec10
movq %rax, -0x38(%rbp)
cmpq $0x0, -0x38(%rbp)
jbe 0x3bc0
movl $0x0, -0x2c(%rbp)
movq 0x73401(%rip), %rax     # 0x76fc8
movq (%rax), %rdi
callq 0x31f0
jmp 0x3dd0
xorl %eax, %eax
movl %eax, %edi
movl $0x4d524d, %edx         # imm = 0x4D524D
movl %edx, %esi
callq 0x15420
movq %rax, -0x58(%rbp)
movq 0x73591(%rip), %rax     # 0x77180
andq $0x40000, %rax          # imm = 0x40000
cmpq $0x0, %rax
je 0x3c26
movq 0x74826(%rip), %rsi     # 0x78428
movl $0x40000, %edi          # imm = 0x40000
xorl %edx, %edx
leaq 0x604cc(%rip), %rcx     # 0x640dc
callq 0x5ed0
movq -0x50(%rbp), %rdi
movl $0x40000, %esi          # imm = 0x40000
callq 0x55c0
movl %eax, -0x2c(%rbp)
movq -0x28(%rbp), %rdi
movq 0x747f7(%rip), %rsi     # 0x78428
addq $0x8, %rsi
movq -0x50(%rbp), %rax
movq 0x38(%rax), %rdx
movq -0x60(%rbp), %rcx
movq -0x50(%rbp), %rax
subq 0x38(%rax), %rcx
movq -0x58(%rbp), %r8
leaq 0x643ce(%rip), %r9      # 0x68022
xorl %eax, %eax
movl $0x0, (%rsp)
callq 0x355f0
movq %rax, -0x38(%rbp)
cmpq $0x0, -0x38(%rbp)
jbe 0x3c74
movl $0x0, -0x2c(%rbp)
movq 0x7334d(%rip), %rax     # 0x76fc8
movq (%rax), %rdi
callq 0x31f0
jmp 0x3dd0
xorl %eax, %eax
movl %eax, %edi
movl $0x4655, %edx           # imm = 0x4655
movl %edx, %esi
callq 0x15420
movq %rax, -0x58(%rbp)
movq 0x734dd(%rip), %rax     # 0x77180
andq $0x40000, %rax          # imm = 0x40000
cmpq $0x0, %rax
je 0x3cde
movq 0x74772(%rip), %rsi     # 0x78428
movl $0x40000, %edi          # imm = 0x40000
xorl %edx, %edx
leaq 0x60418(%rip), %rcx     # 0x640dc
callq 0x5ed0
movq -0x28(%rbp), %rdi
movq -0x50(%rbp), %rsi
movl $0x40000, %edx          # imm = 0x40000
callq 0x38530
movl %eax, -0x2c(%rbp)
cmpl $0x0, -0x2c(%rbp)
jne 0x3d1a
movq -0x28(%rbp), %rdi
movq 0x74739(%rip), %rsi     # 0x78428
addq $0x3c, %rsi
movq -0x58(%rbp), %rdx
leaq 0x64330(%rip), %rcx     # 0x6802e
xorl %r8d, %r8d
callq 0x385f0
movq %rax, -0x38(%rbp)
cmpq $0x0, -0x38(%rbp)
jbe 0x3d18
movl $0x0, -0x2c(%rbp)
jmp 0x3d1a
movq 0x732a7(%rip), %rax     # 0x76fc8
movq (%rax), %rdi
callq 0x31f0
jmp 0x3dd0
xorl %eax, %eax
movl %eax, %edi
movl $0x62564f46, %edx       # imm = 0x62564F46
movl %edx, %esi
callq 0x15420
movq %rax, -0x58(%rbp)
movq 0x73437(%rip), %rax     # 0x77180
andq $0x40000, %rax          # imm = 0x40000
cmpq $0x0, %rax
je 0x3d84
movq 0x746cc(%rip), %rsi     # 0x78428
movl $0x40000, %edi          # imm = 0x40000
xorl %edx, %edx
leaq 0x60372(%rip), %rcx     # 0x640dc
callq 0x5ed0
movq -0x28(%rbp), %rdi
movq -0x50(%rbp), %rsi
movl $0x40000, %edx          # imm = 0x40000
callq 0x3a1e0
movl %eax, -0x2c(%rbp)
cmpl $0x0, -0x2c(%rbp)
jne 0x3dc7
movq -0x28(%rbp), %rdi
movq -0x50(%rbp), %rsi
movq 0x7468f(%rip), %rdx     # 0x78428
movq -0x58(%rbp), %rcx
leaq 0x6428f(%rip), %r8      # 0x68033
xorl %r9d, %r9d
movl $0x0, (%rsp)
callq 0x3a9e0
movq %rax, -0x38(%rbp)
cmpq $0x0, -0x38(%rbp)
jbe 0x3dc5
movl $0x0, -0x2c(%rbp)
jmp 0x3dc7
jmp 0x3dd0
movl $0xffffffff, -0x2c(%rbp) # imm = 0xFFFFFFFF
cmpl $0x1, -0x2c(%rbp)
jne 0x3de1
movl -0x64(%rbp), %edi
callq 0x1ef50
movl %eax, -0x64(%rbp)
movq -0x60(%rbp), %rsi
subq $0x1, %rsi
movl $0x40000, %edi          # imm = 0x40000
xorl %edx, %edx
leaq 0x60302(%rip), %rcx     # 0x640f9
callq 0x5ed0
movq 0x7337d(%rip), %rax     # 0x77180
andq $0x40000, %rax          # imm = 0x40000
cmpq $0x0, %rax
je 0x3e3a
leaq 0x602e5(%rip), %rdi     # 0x640fb
movb $0x0, %al
callq 0x3110
addl -0x64(%rbp), %eax
movl %eax, -0x64(%rbp)
cmpl $0x1, -0x2c(%rbp)
jne 0x3e38
movl -0x2c(%rbp), %edi
callq 0x19930
movb $0x0, %al
callq 0xba00
jmp 0x3e3a
movl -0x64(%rbp), %edi
callq 0x1ef50
movl %eax, -0x64(%rbp)
movq -0x58(%rbp), %rdi
callq 0x1de30
jmp 0x3ec5
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
cmpq %rax, 0x745ac(%rip)     # 0x78408
jne 0x3e68
movq -0x60(%rbp), %rax
movq %rax, -0x48(%rbp)
jmp 0x3e89
cmpq $0x0, 0x74598(%rip)     # 0x78408
jbe 0x3e7f
movq 0x7458f(%rip), %rax     # 0x78408
movq %rax, -0x48(%rbp)
jmp 0x3e87
movq $0x40, -0x48(%rbp)
jmp 0x3e89
cmpq $0x0, -0x48(%rbp)
je 0x3ec3
movq -0x28(%rbp), %rdi
movq 0x7458d(%rip), %rsi     # 0x78428
movq -0x60(%rbp), %rdx
movq -0x48(%rbp), %rcx
movl $0x10, %r8d
xorl %r9d, %r9d
movl $0x0, (%rsp)
callq 0x8aa0
movl -0x64(%rbp), %edi
callq 0x1ef50
movl %eax, -0x64(%rbp)
jmp 0x3ec5
movq -0x58(%rbp), %rdi
callq 0x1f830
movq -0x58(%rbp), %rdi
callq 0x1a4d0
movq %rax, -0x58(%rbp)
movl $0x1, %edi
callq 0x1ef50
movl %eax, -0x64(%rbp)
cmpq $0x0, -0x28(%rbp)
je 0x3f2f
movq -0x28(%rbp), %rdi
callq 0x30e0
cmpl $0x0, %eax
je 0x3f2f
movq 0x730f4(%rip), %rax     # 0x76ff8
movq (%rax), %rdi
movq 0x7455a(%rip), %rdx     # 0x78468
movq -0x18(%rbp), %rcx
leaq 0x601ee(%rip), %rsi     # 0x64107
movb $0x0, %al
callq 0x3170
movq 0x730d1(%rip), %rax     # 0x76ff8
movq (%rax), %rdi
callq 0x20840
jmp 0x3f31
movb $0x0, %al
callq 0x208d0
movl $0x1, %edi
callq 0x1ef50
movl %eax, -0x64(%rbp)
jmp 0x3464
movq 0x7322f(%rip), %rax     # 0x77180
andq $0x400, %rax            # imm = 0x400
cmpq $0x0, %rax
je 0x3f64
movb $0x0, %al
callq 0x24a30
movl -0x2c(%rbp), %eax
addq $0xa0, %rsp
popq %rbp
retq