// File: /workspace/github_c_makefile_star2_O0/inflex[P]ripMIME/MIME_headers.c
// Function: MIMEH_parse_header_parameter
int MIMEH_parse_header_parameter( struct MIMEH_header_info *hinfo,  char *data, char *searchstr, char *output_value, int output_value_size, char **data_end_point  )
{
    int return_value = 0;
    char *p;
    char *hl;

    // Set the data end point to be the beginning of the data, as we
    //      have not yet searched through any of the header data
    *data_end_point = data;

    // Duplicate and convert to lowercase the header data
    //      that we have been provided with.
    hl = strdup(data);
    //PLD_strlower((unsigned char *)hl);
    PLD_strlower(hl);

    if (MIMEH_DNORMAL) LOGGER_log("%s:%d:MIMEH_parse_header_parameter:DEBUG: Seeking '%s' in '%s'", FL, searchstr, hl);

    // Look for the search string we're after (ie, filename, name, location etc)
    if (strncmp(hl,searchstr,strlen(searchstr))==0) p = hl; else p = NULL;
    //  p = strstr (hl, searchstr); //TESTING
    if (p != NULL)
    {
        char *string = NULL;

        if (MIMEH_DNORMAL) LOGGER_log("%s:%d:MIMEH_parse_header_parameter:DEBUG: found %s in %s", FL, searchstr, p);

        // Work out where in the -original- string the located parameter is.
        //      We need to work from the original string because we need to
        //      preserve case and our searching string is in _lower-case_.
        //
        //  After we've located it, we offset the pointer past the string we
        //      searched for.  At this position, we should see a separator of
        //      some type in the set [*;:=\t ].

        string = p -hl +data +strlen(searchstr);

        /**
         ** After searching for our parameter, if we've got a
         ** basic match via strstr, we should then proceed to
         ** check that the characters either side of it are
         ** relevant to a typical parameter specification
         **
         ** the characters *, =, <space> and tab can succeed a
         ** parameter name.
         **/
        switch (*string) {
            case '*':
            case '=':
            case ' ':
            case '\t':
                /**
                 ** Permitted characters were found after the parameter name
                 ** so continue on...
                 **/
                break;
            default:
                /**
                 ** Something other than the permitted characters was found,
                 ** this implies (assumed) that the string match was actually
                 ** just a bit of good luck, return to caller
                 **/
                if (hl) free(hl);
                return 1;
        } /** Switch **/

        /**
         ** Don't forget to also test the character _BEFORE_ the search string
         **/
        if (1)
        {
            char *before_string;

            before_string = string -1 -strlen(searchstr);
            if (before_string >= data)
            {
                /**
                 ** The characters, <space>, <tab>, ;, : may preceed a parameter name
                 **/
                switch (*(before_string)) {
                    case ';':
                    case ':':
                    case ' ':
                    case '\t':
                        /**
                         ** Permitted characters were found after the parameter name
                         ** so continue on...
                         **/
                        break;
                    default:
                        /**
                         ** Something other than the permitted characters was found,
                         ** this implies (assumed) that the string match was actually
                         ** just a bit of good luck, return to caller
                         **/
                        if (hl) free(hl);
                        return 1;
                } /** Switch before_string **/
            } /** if before_string > data **/
        } /** 1 **/


        // If the char is a '*', this means we've got a multivalue parameter
        //      which needs to be decoded (ie, name*1*=foo name*2*=bar )
        if (*string == '*')
        {
            DMIMEH LOGGER_log("%s:%d:MIMEH_parse_header_parameter:DEBUG: Found a '*' after the name, so attempting multipart value decode",FL);

            // PLD:DEV:11/08/2004-18H30
            //  Issue: RFC2231 handling
            return_value = MIMEH_recompose_multivalue( hinfo, searchstr, data, output_value, output_value_size, data_end_point);


        } else {

            // skip any spaces
            while (isspace((int) *string )) string++;

            //if ( *string != '=' )
            if ( *string == '\0' )
            {
                if (MIMEH_DNORMAL) LOGGER_log("%s:%d:MIMEH_parse_header_parameter:DEBUG: In '%s' parsing, was expecting a '=' in the start of '%s'\n", FL, searchstr, string );

            }
            else {
                char *endchar;

                // Eliminate multiple = separators.
                // Reference: c030804-006a
                //  PLD:DEV: 11/08/2004-15H15
                while ((*(string +1) == '=')&&(*(string+1) != '\0')) { string++; MIMEH_set_defect(hinfo,MIMEH_DEFECT_MULTIPLE_EQUALS_SEPARATORS); }


                // Get the end of our string
                endchar = string +strlen(string) -1;
                *data_end_point = endchar;

                // Strip off trailing whitespace
                while ((endchar > string)&&(isspace((int)*endchar)))
                {
                    *endchar = '\0';
                    endchar--;
                }

                // we are at the '=' in the header, so skip it
                if (*string == '=') string++;
                else {
                    MIMEH_set_defect(hinfo,MIMEH_DEFECT_MISSING_SEPARATORS);
                }

                // skip any spaces... again
                while ( isspace((int) *string ) ) string++;

                DMIMEH LOGGER_log("%s:%d:MIMEH_parse_header_parameter:DEBUG: Extracting value out of '%s'",FL,string);

                // Because of all the potential exploits and bad behaviour
                //      we have to be really careful about how we determine
                //      what the enclosed string is for our parameter.
                //
                //  Previously we could _assume_ that we just get the last
                //      quote (") on the line and copy out what was between,
                //      unfortunately that doesn't work anymore. Instead now
                //      we have to step along the data stream one char at a
                //      time and make decisions along the way.

                switch (*string) {
                    case '\"':
                    {
                        // If our first char is a quote, then we'll then try and find
                        //      the second quote which closes the string, alas, this is
                        //      not always present in the header data, either due to a
                        //      broken MUA or due to an exploit attempt.
                        char *string_end;

                        DMIMEH LOGGER_log("%s:%d:MIMEH_parse_header_parameter:DEBUG: Using quoted-string tests",FL);

                        // Remove multiple-sequential quotes
                        string++;
                        while ((*string != '\0')&&(*string == '\"')){ string++; MIMEH_set_defect(hinfo,MIMEH_DEFECT_MULTIPLE_QUOTES); }

                        if (*string == '\0') break; // 20071030-0958: Added by Claudio Jeker - prevents overflow.

                        // Find the next quote which isn't sequential to the above
                        //      quotes that we just skipped over
                        string_end = strchr(string+1, '\"');
                        if (string_end != NULL)
                        {
                            DMIMEH LOGGER_log("%s:%d:MIMEH_parse_header_parameter:DEBUG: End of value found",FL);
                            *string_end = '\0';
                            *data_end_point = string_end +1;
                        } else {
                            // If string_end == NULL
                            //
                            // If we didn't find any more quotes, that
                            //      means we've probably got an unbalanced string (oh joy)
                            //      so then we convert to looking for other items such as
                            //      ;\n\r\t and space.
                            //
                            if (hinfo) MIMEH_set_defect(hinfo,MIMEH_DEFECT_UNBALANCED_QUOTES);
                            string_end = strpbrk(string,"; \n\r\t");
                            if (string_end != NULL)
                            {
                                *string_end = '\0';
                                *data_end_point = string_end +1;
                            } else {
                                // There is no termination to the string, instead the
                                //      end of the string is \0.
                            }
                        }
                    }
                    break;

                    default:
                    {
                        char *string_end;

                        DMIMEH LOGGER_log("%s:%d:MIMEH_parse_header_parameter:DEBUG: Using NON-quoted-string tests",FL);
                        string_end = strpbrk(string,"; \n\r\t");
                        if (string_end != NULL)
                        {
                            *string_end = '\0';
                            *data_end_point = string_end +1;
                        } else {
                            // There is no termination to the string, instead the
                            //      end of the string is \0.
                        }
                    }
                    break;
                } /** end of switch **/

                DMIMEH LOGGER_log("%s:%d:MIMEH_parse_header_parameter:DEBUG: Extracting value out of '%s'",FL,string);
                // Trim up and leading/trailing quotes
                if (((*string == '\"')&&(*(string +strlen(string)-1) == '\"'))
                        || ((*string == '\'')&&(*(string +strlen(string)-1) == '\'')) )
                {
                    int slen = strlen(string) -2;
                    char *s = string;
                    if (MIMEH_DNORMAL) LOGGER_log("%s:%d:MIMEH_parse-header_parameter:DEBUG: Stripping quotes from '%s'",FL,string);
                    while (slen > 0)
                    {
                        *s = *(s+1);
                        s++;
                        slen--;
                    }
                    *s = '\0';

                }

                // Now that our string is all cleaned up, save it to our output value
                snprintf( output_value, output_value_size, "%s", string );
                if (MIMEH_DNORMAL) LOGGER_log("%s:%d:MIMEH_parse_header_parameter:DEBUG: Final value = '%s'",FL, output_value);
            } // If the first non-whitespace char wasn't a '='
        } // If the first char after the search-string wasn't a '*'

    }
    else {
        return_value = 1;
    }

    if (hl != NULL) free(hl);

    if (MIMEH_DNORMAL) LOGGER_log("%s:%d:MIMEH_parse_header_parameter:DEBUG: [return=%d] Done seeking for '%s' data_end_point=%p (from %p)",FL, return_value, searchstr, *data_end_point, data);

    return return_value;

}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0xe0, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movq %rcx, -0x28(%rbp)
movl %r8d, -0x2c(%rbp)
movq %r9, -0x38(%rbp)
movl $0x0, -0x3c(%rbp)
movq -0x18(%rbp), %rcx
movq -0x38(%rbp), %rax
movq %rcx, (%rax)
movq -0x18(%rbp), %rdi
callq 0x2390
movq %rax, -0x50(%rbp)
movq -0x50(%rbp), %rdi
callq 0x105f0
cmpl $0x1, 0x2645a(%rip)     # 0x3277c
jl 0xc346
movq -0x20(%rbp), %rcx
movq -0x50(%rbp), %r8
leaq 0x10f12(%rip), %rdi     # 0x1d245
leaq 0x10134(%rip), %rsi     # 0x1c46e
movl $0x62c, %edx            # imm = 0x62C
movb $0x0, %al
callq 0x117c0
movq -0x50(%rbp), %rax
movq %rax, -0x98(%rbp)
movq -0x20(%rbp), %rax
movq %rax, -0x90(%rbp)
movq -0x20(%rbp), %rdi
callq 0x2100
movq -0x98(%rbp), %rdi
movq -0x90(%rbp), %rsi
movq %rax, %rdx
callq 0x2090
cmpl $0x0, %eax
jne 0xc38a
movq -0x50(%rbp), %rax
movq %rax, -0x48(%rbp)
jmp 0xc392
movq $0x0, -0x48(%rbp)
cmpq $0x0, -0x48(%rbp)
je 0xca06
movq $0x0, -0x58(%rbp)
cmpl $0x1, 0x263d0(%rip)     # 0x3277c
jl 0xc3d0
movq -0x20(%rbp), %rcx
movq -0x48(%rbp), %r8
leaq 0x10ec7(%rip), %rdi     # 0x1d284
leaq 0x100aa(%rip), %rsi     # 0x1c46e
movl $0x635, %edx            # imm = 0x635
movb $0x0, %al
callq 0x117c0
movq -0x48(%rbp), %rcx
movq -0x50(%rbp), %rax
subq %rax, %rcx
movq -0x18(%rbp), %rax
addq %rcx, %rax
movq %rax, -0xa8(%rbp)
movq -0x20(%rbp), %rdi
callq 0x2100
movq %rax, %rcx
movq -0xa8(%rbp), %rax
addq %rcx, %rax
movq %rax, -0x58(%rbp)
movq -0x58(%rbp), %rax
movsbl (%rax), %eax
movl %eax, -0x9c(%rbp)
subl $0x9, %eax
je 0xc43e
jmp 0xc417
movl -0x9c(%rbp), %eax
subl $0x20, %eax
je 0xc43e
jmp 0xc424
movl -0x9c(%rbp), %eax
subl $0x2a, %eax
je 0xc43e
jmp 0xc431
movl -0x9c(%rbp), %eax
subl $0x3d, %eax
jne 0xc440
jmp 0xc43e
jmp 0xc45c
cmpq $0x0, -0x50(%rbp)
je 0xc450
movq -0x50(%rbp), %rdi
callq 0x2030
movl $0x1, -0x4(%rbp)
jmp 0xca5c
movq -0x58(%rbp), %rax
addq $-0x1, %rax
movq %rax, -0xb0(%rbp)
movq -0x20(%rbp), %rdi
callq 0x2100
movq %rax, %rdx
movq -0xb0(%rbp), %rax
xorl %ecx, %ecx
subq %rdx, %rcx
addq %rcx, %rax
movq %rax, -0x60(%rbp)
movq -0x60(%rbp), %rax
cmpq -0x18(%rbp), %rax
jb 0xc4e5
movq -0x60(%rbp), %rax
movsbl (%rax), %eax
movl %eax, -0xb4(%rbp)
subl $0x9, %eax
je 0xc4c5
jmp 0xc4a8
movl -0xb4(%rbp), %eax
subl $0x20, %eax
je 0xc4c5
jmp 0xc4b5
movl -0xb4(%rbp), %eax
addl $-0x3a, %eax
subl $0x1, %eax
ja 0xc4c7
jmp 0xc4c5
jmp 0xc4e3
cmpq $0x0, -0x50(%rbp)
je 0xc4d7
movq -0x50(%rbp), %rdi
callq 0x2030
movl $0x1, -0x4(%rbp)
jmp 0xca5c
jmp 0xc4e5
movq -0x58(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x2a, %eax
jne 0xc539
cmpl $0x1, 0x26284(%rip)     # 0x3277c
jl 0xc514
leaq 0x10dbc(%rip), %rdi     # 0x1d2bd
leaq 0xff66(%rip), %rsi      # 0x1c46e
movl $0x686, %edx            # imm = 0x686
movb $0x0, %al
callq 0x117c0
movq -0x10(%rbp), %rdi
movq -0x20(%rbp), %rsi
movq -0x18(%rbp), %rdx
movq -0x28(%rbp), %rcx
movslq -0x2c(%rbp), %r8
movq -0x38(%rbp), %r9
callq 0xbef0
movl %eax, -0x3c(%rbp)
jmp 0xca04
jmp 0xc53b
callq 0x23c0
movq (%rax), %rax
movq -0x58(%rbp), %rcx
movsbl (%rcx), %ecx
movslq %ecx, %rcx
movzwl (%rax,%rcx,2), %eax
andl $0x2000, %eax           # imm = 0x2000
cmpl $0x0, %eax
je 0xc569
movq -0x58(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x58(%rbp)
jmp 0xc53b
movq -0x58(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x0, %eax
jne 0xc5a5
cmpl $0x1, 0x26200(%rip)     # 0x3277c
jl 0xc5a0
movq -0x20(%rbp), %rcx
movq -0x58(%rbp), %r8
leaq 0x10d9b(%rip), %rdi     # 0x1d328
leaq 0xfeda(%rip), %rsi      # 0x1c46e
movl $0x695, %edx            # imm = 0x695
movb $0x0, %al
callq 0x117c0
jmp 0xca02
jmp 0xc5a7
movq -0x58(%rbp), %rax
movsbl 0x1(%rax), %ecx
xorl %eax, %eax
cmpl $0x3d, %ecx
movb %al, -0xb5(%rbp)
jne 0xc5d0
movq -0x58(%rbp), %rax
movsbl 0x1(%rax), %eax
cmpl $0x0, %eax
setne %al
movb %al, -0xb5(%rbp)
movb -0xb5(%rbp), %al
testb $0x1, %al
jne 0xc5dc
jmp 0xc5f8
movq -0x58(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x58(%rbp)
movq -0x10(%rbp), %rdi
movl $0x3, %esi
callq 0xa610
jmp 0xc5a7
movq -0x58(%rbp), %rax
movq %rax, -0xc0(%rbp)
movq -0x58(%rbp), %rdi
callq 0x2100
movq %rax, %rcx
movq -0xc0(%rbp), %rax
addq %rcx, %rax
addq $-0x1, %rax
movq %rax, -0x68(%rbp)
movq -0x68(%rbp), %rcx
movq -0x38(%rbp), %rax
movq %rcx, (%rax)
movq -0x68(%rbp), %rcx
xorl %eax, %eax
cmpq -0x58(%rbp), %rcx
movb %al, -0xc1(%rbp)
jbe 0xc665
callq 0x23c0
movq (%rax), %rax
movq -0x68(%rbp), %rcx
movsbl (%rcx), %ecx
movslq %ecx, %rcx
movzwl (%rax,%rcx,2), %eax
andl $0x2000, %eax           # imm = 0x2000
cmpl $0x0, %eax
setne %al
movb %al, -0xc1(%rbp)
movb -0xc1(%rbp), %al
testb $0x1, %al
jne 0xc671
jmp 0xc686
movq -0x68(%rbp), %rax
movb $0x0, (%rax)
movq -0x68(%rbp), %rax
addq $-0x1, %rax
movq %rax, -0x68(%rbp)
jmp 0xc62c
movq -0x58(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x3d, %eax
jne 0xc6a0
movq -0x58(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x58(%rbp)
jmp 0xc6ae
movq -0x10(%rbp), %rdi
movl $0x8, %esi
callq 0xa610
jmp 0xc6b0
callq 0x23c0
movq (%rax), %rax
movq -0x58(%rbp), %rcx
movsbl (%rcx), %ecx
movslq %ecx, %rcx
movzwl (%rax,%rcx,2), %eax
andl $0x2000, %eax           # imm = 0x2000
cmpl $0x0, %eax
je 0xc6de
movq -0x58(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x58(%rbp)
jmp 0xc6b0
cmpl $0x1, 0x26097(%rip)     # 0x3277c
jl 0xc705
movq -0x58(%rbp), %rcx
leaq 0x10c9b(%rip), %rdi     # 0x1d38d
leaq 0xfd75(%rip), %rsi      # 0x1c46e
movl $0x6b5, %edx            # imm = 0x6B5
movb $0x0, %al
callq 0x117c0
movq -0x58(%rbp), %rax
movb (%rax), %al
subb $0x22, %al
jne 0xc84a
jmp 0xc715
cmpl $0x1, 0x26060(%rip)     # 0x3277c
jl 0xc738
leaq 0x10caf(%rip), %rdi     # 0x1d3d4
leaq 0xfd42(%rip), %rsi      # 0x1c46e
movl $0x6ca, %edx            # imm = 0x6CA
movb $0x0, %al
callq 0x117c0
movq -0x58(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x58(%rbp)
movq -0x58(%rbp), %rax
movsbl (%rax), %ecx
xorl %eax, %eax
cmpl $0x0, %ecx
movb %al, -0xc2(%rbp)
je 0xc76b
movq -0x58(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x22, %eax
sete %al
movb %al, -0xc2(%rbp)
movb -0xc2(%rbp), %al
testb $0x1, %al
jne 0xc777
jmp 0xc793
movq -0x58(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x58(%rbp)
movq -0x10(%rbp), %rdi
movl $0x1, %esi
callq 0xa610
jmp 0xc744
movq -0x58(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x0, %eax
jne 0xc7a4
jmp 0xc8a4
movq -0x58(%rbp), %rdi
addq $0x1, %rdi
movl $0x22, %esi
callq 0x2110
movq %rax, -0x70(%rbp)
cmpq $0x0, -0x70(%rbp)
je 0xc7fc
cmpl $0x1, 0x25fb4(%rip)     # 0x3277c
jl 0xc7e4
leaq 0x10c47(%rip), %rdi     # 0x1d418
leaq 0xfc96(%rip), %rsi      # 0x1c46e
movl $0x6d7, %edx            # imm = 0x6D7
movb $0x0, %al
callq 0x117c0
movq -0x70(%rbp), %rax
movb $0x0, (%rax)
movq -0x70(%rbp), %rcx
addq $0x1, %rcx
movq -0x38(%rbp), %rax
movq %rcx, (%rax)
jmp 0xc848
cmpq $0x0, -0x10(%rbp)
je 0xc811
movq -0x10(%rbp), %rdi
movl $0x2, %esi
callq 0xa610
movq -0x58(%rbp), %rdi
leaq 0x10c39(%rip), %rsi     # 0x1d455
callq 0x22e0
movq %rax, -0x70(%rbp)
cmpq $0x0, -0x70(%rbp)
je 0xc844
movq -0x70(%rbp), %rax
movb $0x0, (%rax)
movq -0x70(%rbp), %rcx
addq $0x1, %rcx
movq -0x38(%rbp), %rax
movq %rcx, (%rax)
jmp 0xc846
jmp 0xc846
jmp 0xc848
jmp 0xc8a4
cmpl $0x1, 0x25f2b(%rip)     # 0x3277c
jl 0xc86d
leaq 0x10c01(%rip), %rdi     # 0x1d45b
leaq 0xfc0d(%rip), %rsi      # 0x1c46e
movl $0x6f4, %edx            # imm = 0x6F4
movb $0x0, %al
callq 0x117c0
movq -0x58(%rbp), %rdi
leaq 0x10bdd(%rip), %rsi     # 0x1d455
callq 0x22e0
movq %rax, -0x78(%rbp)
cmpq $0x0, -0x78(%rbp)
je 0xc8a0
movq -0x78(%rbp), %rax
movb $0x0, (%rax)
movq -0x78(%rbp), %rcx
addq $0x1, %rcx
movq -0x38(%rbp), %rax
movq %rcx, (%rax)
jmp 0xc8a2
jmp 0xc8a2
jmp 0xc8a4
cmpl $0x1, 0x25ed1(%rip)     # 0x3277c
jl 0xc8cb
movq -0x58(%rbp), %rcx
leaq 0x10ad5(%rip), %rdi     # 0x1d38d
leaq 0xfbaf(%rip), %rsi      # 0x1c46e
movl $0x702, %edx            # imm = 0x702
movb $0x0, %al
callq 0x117c0
movq -0x58(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x22, %eax
jne 0xc8ff
movq -0x58(%rbp), %rax
movq %rax, -0xd0(%rbp)
movq -0x58(%rbp), %rdi
callq 0x2100
movq %rax, %rcx
movq -0xd0(%rbp), %rax
movsbl -0x1(%rax,%rcx), %eax
cmpl $0x22, %eax
je 0xc93b
movq -0x58(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x27, %eax
jne 0xc9bf
movq -0x58(%rbp), %rax
movq %rax, -0xd8(%rbp)
movq -0x58(%rbp), %rdi
callq 0x2100
movq %rax, %rcx
movq -0xd8(%rbp), %rax
movsbl -0x1(%rax,%rcx), %eax
cmpl $0x27, %eax
jne 0xc9bf
movq -0x58(%rbp), %rdi
callq 0x2100
subq $0x2, %rax
movl %eax, -0x7c(%rbp)
movq -0x58(%rbp), %rax
movq %rax, -0x88(%rbp)
cmpl $0x1, 0x25e1f(%rip)     # 0x3277c
jl 0xc97d
movq -0x58(%rbp), %rcx
leaq 0x10b39(%rip), %rdi     # 0x1d4a3
leaq 0xfafd(%rip), %rsi      # 0x1c46e
movl $0x709, %edx            # imm = 0x709
movb $0x0, %al
callq 0x117c0
jmp 0xc97f
cmpl $0x0, -0x7c(%rbp)
jle 0xc9b5
movq -0x88(%rbp), %rax
movb 0x1(%rax), %cl
movq -0x88(%rbp), %rax
movb %cl, (%rax)
movq -0x88(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x88(%rbp)
movl -0x7c(%rbp), %eax
addl $-0x1, %eax
movl %eax, -0x7c(%rbp)
jmp 0xc97f
movq -0x88(%rbp), %rax
movb $0x0, (%rax)
movq -0x28(%rbp), %rdi
movslq -0x2c(%rbp), %rsi
movq -0x58(%rbp), %rcx
leaq 0x125d8(%rip), %rdx     # 0x1efaa
movb $0x0, %al
callq 0x2130
cmpl $0x1, 0x25d9c(%rip)     # 0x3277c
jl 0xca00
movq -0x28(%rbp), %rcx
leaq 0x10afb(%rip), %rdi     # 0x1d4e8
leaq 0xfa7a(%rip), %rsi      # 0x1c46e
movl $0x716, %edx            # imm = 0x716
movb $0x0, %al
callq 0x117c0
jmp 0xca02
jmp 0xca04
jmp 0xca0d
movl $0x1, -0x3c(%rbp)
cmpq $0x0, -0x50(%rbp)
je 0xca1d
movq -0x50(%rbp), %rdi
callq 0x2030
cmpl $0x1, 0x25d58(%rip)     # 0x3277c
jl 0xca56
movl -0x3c(%rbp), %ecx
movq -0x20(%rbp), %r8
movq -0x38(%rbp), %rax
movq (%rax), %r9
movq -0x18(%rbp), %rax
leaq 0x10ae6(%rip), %rdi     # 0x1d525
leaq 0xfa28(%rip), %rsi      # 0x1c46e
movl $0x721, %edx            # imm = 0x721
movq %rax, (%rsp)
movb $0x0, %al
callq 0x117c0
movl -0x3c(%rbp), %eax
movl %eax, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0xe0, %rsp
popq %rbp
retq
nopl (%rax,%rax)