// File: /workspace/github_c_makefile_star2_O0/NedFreed[P]msglint/msglint.c
// Function: parseheaders
static int parseheaders(msgcontext *ctx, const char **pmsg,
			int *plen, int htype)
{
    const char *line, *vline, *fieldbody, *msg = *pmsg;
    struct headmap *hmap;
    dbinfo db;
    int firstline = 1, mandhead, startline, hflags = 0, hinum, j, pos;
    headinfo hinfo[mischead + 1];
    unsigned char duptab[DUPTABSIZE];

    /* init header info and duplicate table */
    memset(duptab, 0, sizeof (duptab));
    memset(hinfo, 0, sizeof (hinfo));

    /* allocate MIME info, if necessary */
    if (ctx->mcur == ctx->mpart) {
	ctx->mcur = malloc(sizeof (MIMEinfo));
	if (ctx->mcur == NULL) {
	    wprintf(NULL, w_fatal, "out of memory");
	    return (-1);
	}
	memset(ctx->mcur, 0, sizeof (MIMEinfo));
    } else {
	for (j = 0; j < 10; ++j) {
	    if (ctx->mcur->keep[j] != NULL) {
		ctx->mcur->keep[j]->next = msgfree;
		msgfree = ctx->mcur->keep[j];
		ctx->mcur->keep[j] = NULL;
	    }
	}
    }
    ctx->mcur->typenum = text;
    if (ctx->mpart && ctx->mpart->indigest == 1) {
	ctx->mcur->typenum = message;
    }
    ctx->mcur->cte = cte_default;
    ctx->mcur->saw8bit = 0;
    ctx->mcur->saw8char = 0;
    ctx->mcur->csetid = us_ascii;
    ctx->mcur->asciisubset = 0;
    ctx->mcur->cset7bit = 0;
    startline = ctx->lineno;
    db.endline = ctx->lineno;
    for (;;) {

	/* look for a header name */
	line = vline = msg;
	while (isalpha(*msg) || isdigit(*msg) || *msg == '-') {
	    ++msg;
	}
	/* handle end of line */
	if ((*msg == '\n' || *msg == '\r') && msg == line) {
	    ++line, ++ctx->lineno;
	    break;
	}
	/* handle "header   : body" */
	for (j = 0; *msg == ' ' || *msg == '\t'; ++msg, ++j)
	    ;
	if (*msg == '\n' || *msg == '\r') {
	    msg -= j;
	    j = 0;
	}
	hmap = &emptyhead;
	if (*msg == '\0') {
	    wprintf(NULL, w_error, "message ended in middle of header at "
		    "line %d", ctx->lineno);
	    break;
	}
	if (*msg != ':' || msg == line) {
	    wprintf(NULL, w_error, "unexpected character %c"
		    " found in header on line %d", *msg, ctx->lineno);
	} else /* msg == ':' */ {
	    if (j) {
		wprintf(NULL, w_warn, "spaces between header name and "
			"':' unwise on line %d", ctx->lineno);
	    }
	    
	    /* lookup the header name */
	    for (hmap = known_headers; hmap->str != NULL &&
		 (strlen(hmap->str) != msg - line - j ||
		  strncasecmp(hmap->str, line, msg - line - j)); ++hmap)
		;
	    fieldbody = ++msg;
	    hflags |= hmap->flags;
	}
	firstline = 0;

	/* find the end of the header */
	db.startline = ctx->lineno;
	db.headname = line;
	db.headlen = msg - line - j - 1;
	db.flags = 0;
	pos = msg - line;
	while (*msg != '\0') {
	    if (*msg == '\n' || *msg == '\r') {
		if (htype == HEAD_DSN || htype == HEAD_RCPT ||
		    htype == HEAD_MTRKM || htype == HEAD_MTRKR ||
		    htype == HEAD_MDN || htype == HEAD_TEXT) {
		    MD5Update(&ctx->md5, (unsigned char *) vline, msg - vline);
		    MD5Update(&ctx->md5, (unsigned char *) "\r\n", 2);
		}
		if (pos > 80) {
		    wprintf(NULL, w_warn, "line too long in header '%.*s' "
			    "at line %d", fieldbody - line, line, ctx->lineno);
		}
		pos = 0;
		++ctx->lineno;
		if (*msg == '\r' && msg[1] == '\n') ++msg;
		vline = ++msg;
		if (*msg != ' ' && *msg != '\t') {
		    break;
		}
		while (*msg == ' ' || *msg == '\t') ++msg, ++pos;
		if (*msg == '\n' || *msg == '\r') {
		    wprintf(NULL, w_warn, "empty continuation line in "
			    "header '%.*s' at line %d",
			    fieldbody - line, line, ctx->lineno);
		    continue;
		}
	    }
	    ++msg, ++pos;
	}
	db.endline = ctx->lineno - 1;

	/* parse the header */
	if (hmap->type != head_unknown) {
	    if (hmap->type == returnpath && reply_line == NULL) {
		reply_line = fieldbody + 1;
		reply_len = msg - fieldbody - 1;
	    }

	    /* check for duplicate headers */
            hinum = hmap - known_headers;
	    if (duptab[hinum] && (hmap->flags & DUPOK) == 0) {
	    	wprintf(&db, htype == HEAD_DSN || htype == HEAD_RCPT ||
			htype == HEAD_MTRKM || htype == HEAD_MTRKR ||
			htype == HEAD_MDN ? w_error : w_warn,
			"duplicate ");
	    }
	    duptab[hinum] = 1;
	    hinfo[hmap->type].flags = HEAD_PRESENT;
	    hinfo[hmap->type].value = 0;
	    parsehead(ctx, hmap, fieldbody, msg - fieldbody - 1, htype,
	    	hinfo + hmap->type, &db);
	} else if (hmap != &emptyhead) {
	    wprintf(&db, htype == HEAD_DSN || htype == HEAD_RCPT ||
		    htype == HEAD_MTRKM || htype == HEAD_MTRKR ||
		    htype == HEAD_MDN ? w_error : w_unknown,
		    "unknown ");
	}

	/* advance */
	line = msg;
    }
    *plen -= line - *pmsg;
    *pmsg = line;

    /* handle silence */
    if (silent) return (0);
    
    /* check for mandatory headers in header blocks */
    mandhead = 0;
    switch (htype) {
    	case HEAD_MSG:
	    if (hflags & HF_PATH) {
		mandhead = HF_NEWSGROUPS | HF_MID | HF_SUBJECT | HF_DATE |
		    HF_FROM;
		break;
	    }
	    mandhead = HF_DATE | HF_FROM | HF_RETURNPATH;
	    if ((hflags & (HF_TO|HF_CC|HF_BCC)) == 0) {
		wprintf(NULL, w_ok, "None of To, CC, or BCC "
			"fields specified in lines %d-%d - " RFC_TOCCBCC
			" used to require at least one such field",
			startline, db.endline);
	    }
    	    break;
    	    
        case HEAD_DSN:
            mandhead = HF_REPORTMTA;
            break;
            
        case HEAD_RCPT:
            mandhead = HF_ACTION | HF_STATUS | HF_FINALRCPT;
            break;

	case HEAD_MTRKM:
	    mandhead = HF_REPORTMTA | HF_ORIGENVID | HF_ARRIVDATE;
	    break;

	case HEAD_MTRKR:
	    mandhead = HF_ACTION | HF_STATUS | HF_FINALRCPT | HF_ORIGRCPT;
	    break;
        
        case HEAD_INNER:
            if ((hflags & (HF_DATE|HF_FROM|HF_SUBJECT)) == 0) {
                wprintf(NULL, w_error, "At least one of Date, From, Subject "
			"required lines %d-%d (" RFC_MIME_DFS ")",
			startline, db.endline);
            }
            break;

	  case HEAD_EXTB:
	    if ((hflags & HF_CID) == 0) {
		wprintf(NULL, w_error, "Content-ID required lines %d-%d ("
			RFC_EXTB_CID ")", startline, db.endline);
	    }
	    break;
    }
    if (mandhead) for (hmap = known_headers; hmap->str != NULL; ++hmap) {
        if ((hmap->flags & mandhead) != 0 &&
            (hmap->flags & mandhead & hflags) == 0) {
            wprintf(NULL, w_error, "missing mandatory header '%s' lines %d-%d",
            	   hmap->str, startline, db.endline);
        }
    }

    /* check for name content-type param and missing disposition filename */
    if ((hinfo[contenttype].flags & 1) &&
	(hinfo[contentdisp].flags & 1) == 0) {
	wprintf(NULL, w_error, "Content-Type 'name' parameter deprecated in "
		"favor of Content-Disposition 'filename' parameter ("
		RFC_CDISP_FN ") lines %d-%d", startline, db.endline);
    }
    
    /* make sure return-path is empty on a multipart/report */
    if (ctx->mcur->inreport && (hinfo[returnpath].flags & 1)) {
        wprintf(NULL, w_error, "return-path should be empty on "
		"multipart/report lines %d-%d", startline, db.endline);
    }
    
    /* if from multi-valued, sender is mandatory */
    if ((hinfo[fromhead].flags & 1) && !(hflags & HF_SENDER)) {
        wprintf(NULL, w_error, "'Sender' header is mandatory when 'From' is "
		"multi-valued lines %d-%d", startline, db.endline);
    }

    /* if Lines is present, Newsgroups must also be there */
    if (hflags & HF_LINES) {
	if (!(hflags & HF_NEWSGROUPS)) {
	    wprintf(NULL, w_warn, "'Lines' header is not standardized for use "
		    "in email lines %d-%d", startline, db.endline);
	}
	if (htype == HEAD_MSG) {
	    ctx->lines = hinfo[lineshead].value;
	    ctx->endhead = ctx->lineno;
	}
    }
    
    /* save content-transfer-encoding */
    if (hinfo[contentte].value) {
        ctx->mcur->cte = (cteid) hinfo[contentte].value;
        if (ctx->mcur->cte >= quoted_printable &&
            (ctx->mcur->typenum == multipart ||
             (ctx->mcur->typenum == message &&
              tokcomp("rfc822", -1, ctx->mcur->keep[K_SUBTYPE]) == 0))) {
            wprintf(NULL, w_error, "only 7-bit, 8-bit and binary "
		    "content-transfer-encodings are permitted on "
		    "compound media types, line %d", ctx->lineno);
        }
        if (ctx->mcur->cte == cte8bit && ctx->mpart != NULL &&
            ctx->mpart->cte != cte8bit) {
            wprintf(NULL, w_error, "mismatch between inner "
		    "content-transfer-encoding and that of enclosing "
		    "multipart, line %d", ctx->lineno);
        }
    }
    
    /* warn about charset/cte mismatch */
    if (ctx->mcur->typenum == text && ctx->mcur->cte == cte8bit) {
        if (ctx->mcur->csetid == us_ascii) {
	    wprintf(NULL, w_error, "charset 'us-ascii' doesn't match "
		    "content-transfer-encoding line %d", ctx->lineno);
	} else if (ctx->mcur->cset7bit) {
	    wprintf(NULL, w_error, "charset '%t' doesn't match "
		    "content-transfer-encoding line %d",
		    ctx->mcur->keep[K_CHARSET], ctx->lineno);
	}
    }

    /* put multipart on boundary list */
    if (ctx->mcur->typenum == multipart) {
	ctx->mcur->next = ctx->mpart;
	ctx->mpart = ctx->mcur;
    }

    return (0);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x140, %rsp            # imm = 0x140
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movl %ecx, -0x24(%rbp)
movq -0x18(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x48(%rbp)
movl $0x1, -0x6c(%rbp)
movl $0x0, -0x78(%rbp)
leaq -0x120(%rbp), %rdi
xorl %esi, %esi
movl $0x4a, %edx
callq 0x20f0
leaq -0xd0(%rbp), %rdi
xorl %esi, %esi
movl $0x40, %edx
callq 0x20f0
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq -0x10(%rbp), %rcx
cmpq 0x8(%rcx), %rax
jne 0x4642
movl $0x88, %edi
callq 0x2130
movq %rax, %rcx
movq -0x10(%rbp), %rax
movq %rcx, (%rax)
movq -0x10(%rbp), %rax
cmpq $0x0, (%rax)
jne 0x462d
xorl %eax, %eax
movl %eax, %edi
leaq 0xb0fb(%rip), %rsi      # 0xf70e
leaq 0xc3f7(%rip), %rdx      # 0x10a11
movb $0x0, %al
callq 0x2e50
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x5291
movq -0x10(%rbp), %rax
movq (%rax), %rdi
xorl %esi, %esi
movl $0x88, %edx
callq 0x20f0
jmp 0x46b2
movl $0x0, -0x80(%rbp)
cmpl $0xa, -0x80(%rbp)
jge 0x46b0
movq -0x10(%rbp), %rax
movq (%rax), %rax
movslq -0x80(%rbp), %rcx
cmpq $0x0, (%rax,%rcx,8)
je 0x46a3
movq 0x108c8(%rip), %rcx     # 0x14f30
movq -0x10(%rbp), %rax
movq (%rax), %rax
movslq -0x80(%rbp), %rdx
movq (%rax,%rdx,8), %rax
movq %rcx, (%rax)
movq -0x10(%rbp), %rax
movq (%rax), %rax
movslq -0x80(%rbp), %rcx
movq (%rax,%rcx,8), %rax
movq %rax, 0x108a0(%rip)     # 0x14f30
movq -0x10(%rbp), %rax
movq (%rax), %rax
movslq -0x80(%rbp), %rcx
movq $0x0, (%rax,%rcx,8)
jmp 0x46a5
movl -0x80(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x80(%rbp)
jmp 0x4649
jmp 0x46b2
movq -0x10(%rbp), %rax
movq (%rax), %rax
movl $0x2, 0x74(%rax)
movq -0x10(%rbp), %rax
cmpq $0x0, 0x8(%rax)
je 0x46e7
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rax
cmpl $0x1, 0x50(%rax)
jne 0x46e7
movq -0x10(%rbp), %rax
movq (%rax), %rax
movl $0x7, 0x74(%rax)
movq -0x10(%rbp), %rax
movq (%rax), %rax
movl $0x0, 0x78(%rax)
movq -0x10(%rbp), %rax
movq (%rax), %rax
movl $0x0, 0x5c(%rax)
movq -0x10(%rbp), %rax
movq (%rax), %rax
movl $0x0, 0x60(%rax)
movq -0x10(%rbp), %rax
movq (%rax), %rax
movl $0x0, 0x70(%rax)
movq -0x10(%rbp), %rax
movq (%rax), %rax
movl $0x0, 0x68(%rax)
movq -0x10(%rbp), %rax
movq (%rax), %rax
movl $0x0, 0x6c(%rax)
movq -0x10(%rbp), %rax
movl 0x10(%rax), %eax
movl %eax, -0x74(%rbp)
movq -0x10(%rbp), %rax
movl 0x10(%rax), %eax
movl %eax, -0x5c(%rbp)
movq -0x48(%rbp), %rax
movq %rax, -0x38(%rbp)
movq %rax, -0x30(%rbp)
callq 0x21d0
movq (%rax), %rax
movq -0x48(%rbp), %rcx
movsbl (%rcx), %ecx
movslq %ecx, %rcx
movzwl (%rax,%rcx,2), %ecx
andl $0x400, %ecx            # imm = 0x400
movb $0x1, %al
cmpl $0x0, %ecx
movb %al, -0x121(%rbp)
jne 0x47c0
callq 0x21d0
movq (%rax), %rax
movq -0x48(%rbp), %rcx
movsbl (%rcx), %ecx
movslq %ecx, %rcx
movzwl (%rax,%rcx,2), %ecx
andl $0x800, %ecx            # imm = 0x800
movb $0x1, %al
cmpl $0x0, %ecx
movb %al, -0x121(%rbp)
jne 0x47c0
movq -0x48(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x2d, %eax
sete %al
movb %al, -0x121(%rbp)
movb -0x121(%rbp), %al
testb $0x1, %al
jne 0x47cc
jmp 0x47da
movq -0x48(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x48(%rbp)
jmp 0x475b
movq -0x48(%rbp), %rax
movsbl (%rax), %eax
cmpl $0xa, %eax
je 0x47f2
movq -0x48(%rbp), %rax
movsbl (%rax), %eax
cmpl $0xd, %eax
jne 0x481a
movq -0x48(%rbp), %rax
cmpq -0x30(%rbp), %rax
jne 0x481a
movq -0x30(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x30(%rbp)
movq -0x10(%rbp), %rax
movl 0x10(%rax), %ecx
addl $0x1, %ecx
movl %ecx, 0x10(%rax)
jmp 0x4e40
movl $0x0, -0x80(%rbp)
movq -0x48(%rbp), %rax
movsbl (%rax), %ecx
movb $0x1, %al
cmpl $0x20, %ecx
movb %al, -0x122(%rbp)
je 0x4848
movq -0x48(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x9, %eax
sete %al
movb %al, -0x122(%rbp)
movb -0x122(%rbp), %al
testb $0x1, %al
jne 0x4854
jmp 0x486d
jmp 0x4856
movq -0x48(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x48(%rbp)
movl -0x80(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x80(%rbp)
jmp 0x4821
movq -0x48(%rbp), %rax
movsbl (%rax), %eax
cmpl $0xa, %eax
je 0x4885
movq -0x48(%rbp), %rax
movsbl (%rax), %eax
cmpl $0xd, %eax
jne 0x48a2
movl -0x80(%rbp), %ecx
movq -0x48(%rbp), %rax
movslq %ecx, %rdx
xorl %ecx, %ecx
subq %rdx, %rcx
addq %rcx, %rax
movq %rax, -0x48(%rbp)
movl $0x0, -0x80(%rbp)
leaq 0x10417(%rip), %rax     # 0x14cc0
movq %rax, -0x50(%rbp)
movq -0x48(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x0, %eax
jne 0x48de
movq -0x10(%rbp), %rax
movl 0x10(%rax), %ecx
xorl %eax, %eax
movl %eax, %edi
leaq 0xae4b(%rip), %rsi      # 0xf716
leaq 0xc14d(%rip), %rdx      # 0x10a1f
movb $0x0, %al
callq 0x2e50
jmp 0x4e40
movq -0x48(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x3a, %eax
jne 0x48f4
movq -0x48(%rbp), %rax
cmpq -0x30(%rbp), %rax
jne 0x4921
movq -0x48(%rbp), %rax
movsbl (%rax), %ecx
movq -0x10(%rbp), %rax
movl 0x10(%rax), %r8d
xorl %eax, %eax
movl %eax, %edi
leaq 0xae08(%rip), %rsi      # 0xf716
leaq 0xc137(%rip), %rdx      # 0x10a4c
movb $0x0, %al
callq 0x2e50
jmp 0x4a08
cmpl $0x0, -0x80(%rbp)
je 0x4947
movq -0x10(%rbp), %rax
movl 0x10(%rax), %ecx
xorl %eax, %eax
movl %eax, %edi
leaq 0xaa38(%rip), %rsi      # 0xf371
leaq 0xc13f(%rip), %rdx      # 0x10a7f
movb $0x0, %al
callq 0x2e50
leaq 0xf7b2(%rip), %rax      # 0x14100
movq %rax, -0x50(%rbp)
movq -0x50(%rbp), %rcx
xorl %eax, %eax
cmpq $0x0, (%rcx)
movb %al, -0x123(%rbp)
je 0x49cc
movq -0x50(%rbp), %rax
movq (%rax), %rdi
callq 0x20b0
movq %rax, %rcx
movq -0x48(%rbp), %rdx
movq -0x30(%rbp), %rax
subq %rax, %rdx
movslq -0x80(%rbp), %rax
subq %rax, %rdx
movb $0x1, %al
cmpq %rdx, %rcx
movb %al, -0x124(%rbp)
jne 0x49c0
movq -0x50(%rbp), %rax
movq (%rax), %rdi
movq -0x30(%rbp), %rsi
movq -0x48(%rbp), %rdx
movq -0x30(%rbp), %rax
subq %rax, %rdx
movslq -0x80(%rbp), %rax
subq %rax, %rdx
callq 0x2140
cmpl $0x0, %eax
setne %al
movb %al, -0x124(%rbp)
movb -0x124(%rbp), %al
movb %al, -0x123(%rbp)
movb -0x123(%rbp), %al
testb $0x1, %al
jne 0x49d8
jmp 0x49eb
jmp 0x49da
movq -0x50(%rbp), %rax
addq $0x20, %rax
movq %rax, -0x50(%rbp)
jmp 0x4952
movq -0x48(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x48(%rbp)
movq %rax, -0x40(%rbp)
movq -0x50(%rbp), %rax
movl 0x18(%rax), %eax
orl -0x78(%rbp), %eax
movl %eax, -0x78(%rbp)
movl $0x0, -0x6c(%rbp)
movq -0x10(%rbp), %rax
movl 0x10(%rax), %eax
movl %eax, -0x60(%rbp)
movq -0x30(%rbp), %rax
movq %rax, -0x68(%rbp)
movq -0x48(%rbp), %rax
movq -0x30(%rbp), %rcx
subq %rcx, %rax
movslq -0x80(%rbp), %rcx
subq %rcx, %rax
subq $0x1, %rax
movl %eax, -0x58(%rbp)
movl $0x0, -0x54(%rbp)
movq -0x48(%rbp), %rax
movq -0x30(%rbp), %rcx
subq %rcx, %rax
movl %eax, -0x84(%rbp)
movq -0x48(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x0, %eax
je 0x4c3c
movq -0x48(%rbp), %rax
movsbl (%rax), %eax
cmpl $0xa, %eax
je 0x4a7e
movq -0x48(%rbp), %rax
movsbl (%rax), %eax
cmpl $0xd, %eax
jne 0x4c1c
cmpl $0x2, -0x24(%rbp)
je 0x4aa2
cmpl $0x3, -0x24(%rbp)
je 0x4aa2
cmpl $0x8, -0x24(%rbp)
je 0x4aa2
cmpl $0x9, -0x24(%rbp)
je 0x4aa2
cmpl $0x4, -0x24(%rbp)
je 0x4aa2
cmpl $0x6, -0x24(%rbp)
jne 0x4ad9
movq -0x10(%rbp), %rdi
addq $0x20, %rdi
movq -0x38(%rbp), %rsi
movq -0x48(%rbp), %rax
movq -0x38(%rbp), %rcx
subq %rcx, %rax
movl %eax, %edx
callq 0xc730
movq -0x10(%rbp), %rdi
addq $0x20, %rdi
leaq 0xbfe5(%rip), %rsi      # 0x10ab4
movl $0x2, %edx
callq 0xc730
cmpl $0x50, -0x84(%rbp)
jle 0x4b12
movq -0x40(%rbp), %rcx
movq -0x30(%rbp), %rax
subq %rax, %rcx
movq -0x30(%rbp), %r8
movq -0x10(%rbp), %rax
movl 0x10(%rax), %r9d
xorl %eax, %eax
movl %eax, %edi
leaq 0xa86d(%rip), %rsi      # 0xf371
leaq 0xbfac(%rip), %rdx      # 0x10ab7
movb $0x0, %al
callq 0x2e50
movl $0x0, -0x84(%rbp)
movq -0x10(%rbp), %rax
movl 0x10(%rax), %ecx
addl $0x1, %ecx
movl %ecx, 0x10(%rax)
movq -0x48(%rbp), %rax
movsbl (%rax), %eax
cmpl $0xd, %eax
jne 0x4b4e
movq -0x48(%rbp), %rax
movsbl 0x1(%rax), %eax
cmpl $0xa, %eax
jne 0x4b4e
movq -0x48(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x48(%rbp)
movq -0x48(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x48(%rbp)
movq %rax, -0x38(%rbp)
movq -0x48(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x20, %eax
je 0x4b7b
movq -0x48(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x9, %eax
je 0x4b7b
jmp 0x4c3c
jmp 0x4b7d
movq -0x48(%rbp), %rax
movsbl (%rax), %ecx
movb $0x1, %al
cmpl $0x20, %ecx
movb %al, -0x125(%rbp)
je 0x4ba4
movq -0x48(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x9, %eax
sete %al
movb %al, -0x125(%rbp)
movb -0x125(%rbp), %al
testb $0x1, %al
jne 0x4bb0
jmp 0x4bcd
movq -0x48(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x48(%rbp)
movl -0x84(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x84(%rbp)
jmp 0x4b7d
movq -0x48(%rbp), %rax
movsbl (%rax), %eax
cmpl $0xa, %eax
je 0x4be5
movq -0x48(%rbp), %rax
movsbl (%rax), %eax
cmpl $0xd, %eax
jne 0x4c1a
movq -0x40(%rbp), %rcx
movq -0x30(%rbp), %rax
subq %rax, %rcx
movq -0x30(%rbp), %r8
movq -0x10(%rbp), %rax
movl 0x10(%rax), %r9d
xorl %eax, %eax
movl %eax, %edi
leaq 0xa76a(%rip), %rsi      # 0xf371
leaq 0xbed3(%rip), %rdx      # 0x10ae1
movb $0x0, %al
callq 0x2e50
jmp 0x4a52
jmp 0x4c1c
movq -0x48(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x48(%rbp)
movl -0x84(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x84(%rbp)
jmp 0x4a52
movq -0x10(%rbp), %rax
movl 0x10(%rax), %eax
subl $0x1, %eax
movl %eax, -0x5c(%rbp)
movq -0x50(%rbp), %rax
cmpl $0x0, 0x8(%rax)
je 0x4db2
movq -0x50(%rbp), %rax
cmpl $0x4, 0x8(%rax)
jne 0x4c8f
cmpq $0x0, 0x102b7(%rip)     # 0x14f20
jne 0x4c8f
movq -0x40(%rbp), %rax
addq $0x1, %rax
movq %rax, 0x102a6(%rip)     # 0x14f20
movq -0x48(%rbp), %rax
movq -0x40(%rbp), %rcx
subq %rcx, %rax
subq $0x1, %rax
movl %eax, 0x10299(%rip)     # 0x14f28
movq -0x50(%rbp), %rax
leaq 0xf466(%rip), %rcx      # 0x14100
subq %rcx, %rax
sarq $0x5, %rax
movl %eax, -0x7c(%rbp)
movslq -0x7c(%rbp), %rax
movzbl -0x120(%rbp,%rax), %eax
cmpl $0x0, %eax
je 0x4d3a
movq -0x50(%rbp), %rax
movl 0x18(%rax), %eax
andl $0x8, %eax
cmpl $0x0, %eax
jne 0x4d3a
movb $0x1, %al
cmpl $0x2, -0x24(%rbp)
movb %al, -0x126(%rbp)
je 0x4d0d
movb $0x1, %al
cmpl $0x3, -0x24(%rbp)
movb %al, -0x126(%rbp)
je 0x4d0d
movb $0x1, %al
cmpl $0x8, -0x24(%rbp)
movb %al, -0x126(%rbp)
je 0x4d0d
movb $0x1, %al
cmpl $0x9, -0x24(%rbp)
movb %al, -0x126(%rbp)
je 0x4d0d
cmpl $0x4, -0x24(%rbp)
sete %al
movb %al, -0x126(%rbp)
movb -0x126(%rbp), %cl
leaq 0xa657(%rip), %rsi      # 0xf371
leaq 0xa9f5(%rip), %rax      # 0xf716
testb $0x1, %cl
cmovneq %rax, %rsi
leaq -0x68(%rbp), %rdi
leaq 0xbde2(%rip), %rdx      # 0x10b15
movb $0x0, %al
callq 0x2e50
movslq -0x7c(%rbp), %rax
movb $0x1, -0x120(%rbp,%rax)
movq -0x50(%rbp), %rax
movl 0x8(%rax), %eax
movl $0x100, -0xd0(%rbp,%rax,8) # imm = 0x100
movq -0x50(%rbp), %rax
movl 0x8(%rax), %eax
movl $0x0, -0xcc(%rbp,%rax,8)
movq -0x10(%rbp), %rdi
movq -0x50(%rbp), %rsi
movq -0x40(%rbp), %rdx
movq -0x48(%rbp), %rax
movq -0x40(%rbp), %rcx
subq %rcx, %rax
subq $0x1, %rax
movl %eax, %ecx
movl -0x24(%rbp), %r8d
leaq -0xd0(%rbp), %r9
movq -0x50(%rbp), %rax
movl 0x8(%rax), %eax
shlq $0x3, %rax
addq %rax, %r9
leaq -0x68(%rbp), %rax
movq %rax, (%rsp)
callq 0x5a70
jmp 0x4e33
leaq 0xff07(%rip), %rax      # 0x14cc0
cmpq %rax, -0x50(%rbp)
je 0x4e31
movb $0x1, %al
cmpl $0x2, -0x24(%rbp)
movb %al, -0x127(%rbp)
je 0x4e04
movb $0x1, %al
cmpl $0x3, -0x24(%rbp)
movb %al, -0x127(%rbp)
je 0x4e04
movb $0x1, %al
cmpl $0x8, -0x24(%rbp)
movb %al, -0x127(%rbp)
je 0x4e04
movb $0x1, %al
cmpl $0x9, -0x24(%rbp)
movb %al, -0x127(%rbp)
je 0x4e04
cmpl $0x4, -0x24(%rbp)
sete %al
movb %al, -0x127(%rbp)
movb -0x127(%rbp), %cl
leaq 0xa90d(%rip), %rsi      # 0xf71e
leaq 0xa8fe(%rip), %rax      # 0xf716
testb $0x1, %cl
cmovneq %rax, %rsi
leaq -0x68(%rbp), %rdi
leaq 0xbcf6(%rip), %rdx      # 0x10b20
movb $0x0, %al
callq 0x2e50
jmp 0x4e33
movq -0x48(%rbp), %rax
movq %rax, -0x30(%rbp)
jmp 0x474f
movq -0x30(%rbp), %rdx
movq -0x18(%rbp), %rax
movq (%rax), %rax
subq %rax, %rdx
movq -0x20(%rbp), %rax
movslq (%rax), %rcx
subq %rdx, %rcx
movl %ecx, (%rax)
movq -0x30(%rbp), %rcx
movq -0x18(%rbp), %rax
movq %rcx, (%rax)
cmpl $0x0, 0xfe7c(%rip)      # 0x14ce8
je 0x4e7a
movl $0x0, -0x4(%rbp)
jmp 0x5291
movl $0x0, -0x70(%rbp)
movl -0x24(%rbp), %eax
movq %rax, -0x130(%rbp)
subq $0x9, %rax
ja 0x4f80
movq -0x130(%rbp), %rax
leaq 0x93a5(%rip), %rcx      # 0xe248
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movl -0x78(%rbp), %eax
andl $0x10000000, %eax       # imm = 0x10000000
cmpl $0x0, %eax
je 0x4ec5
movl $0x28070000, -0x70(%rbp) # imm = 0x28070000
jmp 0x4f80
movl $0x2050000, -0x70(%rbp) # imm = 0x2050000
movl -0x78(%rbp), %eax
andl $0x700000, %eax         # imm = 0x700000
cmpl $0x0, %eax
jne 0x4ef9
movl -0x74(%rbp), %ecx
movl -0x5c(%rbp), %r8d
xorl %eax, %eax
movl %eax, %edi
leaq 0xa425(%rip), %rsi      # 0xf310
leaq 0xbc37(%rip), %rdx      # 0x10b29
movb $0x0, %al
callq 0x2e50
jmp 0x4f80
movl $0x1000, -0x70(%rbp)    # imm = 0x1000
jmp 0x4f80
movl $0xe000, -0x70(%rbp)    # imm = 0xE000
jmp 0x4f80
movl $0x40001800, -0x70(%rbp) # imm = 0x40001800
jmp 0x4f80
movl $0xe400, -0x70(%rbp)    # imm = 0xE400
jmp 0x4f80
movl -0x78(%rbp), %eax
andl $0x70000, %eax          # imm = 0x70000
cmpl $0x0, %eax
jne 0x4f4f
movl -0x74(%rbp), %ecx
movl -0x5c(%rbp), %r8d
xorl %eax, %eax
movl %eax, %edi
leaq 0xa7d5(%rip), %rsi      # 0xf716
leaq 0xbc52(%rip), %rdx      # 0x10b9a
movb $0x0, %al
callq 0x2e50
jmp 0x4f80
movl -0x78(%rbp), %eax
andl $0x1000000, %eax        # imm = 0x1000000
cmpl $0x0, %eax
jne 0x4f7e
movl -0x74(%rbp), %ecx
movl -0x5c(%rbp), %r8d
xorl %eax, %eax
movl %eax, %edi
leaq 0xa7a6(%rip), %rsi      # 0xf716
leaq 0xbc71(%rip), %rdx      # 0x10be8
movb $0x0, %al
callq 0x2e50
jmp 0x4f80
cmpl $0x0, -0x70(%rbp)
je 0x4ff6
leaq 0xf173(%rip), %rax      # 0x14100
movq %rax, -0x50(%rbp)
movq -0x50(%rbp), %rax
cmpq $0x0, (%rax)
je 0x4ff4
movq -0x50(%rbp), %rax
movl 0x18(%rax), %eax
andl -0x70(%rbp), %eax
cmpl $0x0, %eax
je 0x4fe4
movq -0x50(%rbp), %rax
movl 0x18(%rax), %eax
andl -0x70(%rbp), %eax
andl -0x78(%rbp), %eax
cmpl $0x0, %eax
jne 0x4fe4
movq -0x50(%rbp), %rax
movq (%rax), %rcx
movl -0x74(%rbp), %r8d
movl -0x5c(%rbp), %r9d
xorl %eax, %eax
movl %eax, %edi
leaq 0xa740(%rip), %rsi      # 0xf716
leaq 0xbc40(%rip), %rdx      # 0x10c1d
movb $0x0, %al
callq 0x2e50
jmp 0x4fe6
movq -0x50(%rbp), %rax
addq $0x20, %rax
movq %rax, -0x50(%rbp)
jmp 0x4f91
jmp 0x4ff6
movl -0xc8(%rbp), %eax
andl $0x1, %eax
cmpl $0x0, %eax
je 0x5032
movl -0xc0(%rbp), %eax
andl $0x1, %eax
cmpl $0x0, %eax
jne 0x5032
movl -0x74(%rbp), %ecx
movl -0x5c(%rbp), %r8d
xorl %eax, %eax
movl %eax, %edi
leaq 0xa6f2(%rip), %rsi      # 0xf716
leaq 0xbc1c(%rip), %rdx      # 0x10c47
movb $0x0, %al
callq 0x2e50
movq -0x10(%rbp), %rax
movq (%rax), %rax
cmpl $0x0, 0x54(%rax)
je 0x506d
movl -0xb0(%rbp), %eax
andl $0x1, %eax
cmpl $0x0, %eax
je 0x506d
movl -0x74(%rbp), %ecx
movl -0x5c(%rbp), %r8d
xorl %eax, %eax
movl %eax, %edi
leaq 0xa6b7(%rip), %rsi      # 0xf716
leaq 0xbc6a(%rip), %rdx      # 0x10cd0
movb $0x0, %al
callq 0x2e50
movl -0xa8(%rbp), %eax
andl $0x1, %eax
cmpl $0x0, %eax
je 0x50a8
movl -0x78(%rbp), %eax
andl $0x800000, %eax         # imm = 0x800000
cmpl $0x0, %eax
jne 0x50a8
movl -0x74(%rbp), %ecx
movl -0x5c(%rbp), %r8d
xorl %eax, %eax
movl %eax, %edi
leaq 0xa67c(%rip), %rsi      # 0xf716
leaq 0xbc6b(%rip), %rdx      # 0x10d0c
movb $0x0, %al
callq 0x2e50
movl -0x78(%rbp), %eax
andl $0x4000000, %eax        # imm = 0x4000000
cmpl $0x0, %eax
je 0x5105
movl -0x78(%rbp), %eax
andl $0x8000000, %eax        # imm = 0x8000000
cmpl $0x0, %eax
jne 0x50e2
movl -0x74(%rbp), %ecx
movl -0x5c(%rbp), %r8d
xorl %eax, %eax
movl %eax, %edi
leaq 0xa29d(%rip), %rsi      # 0xf371
leaq 0xbc76(%rip), %rdx      # 0x10d51
movb $0x0, %al
callq 0x2e50
cmpl $0x0, -0x24(%rbp)
jne 0x5103
movl -0x9c(%rbp), %ecx
movq -0x10(%rbp), %rax
movl %ecx, 0x14(%rax)
movq -0x10(%rbp), %rax
movl 0x10(%rax), %ecx
movq -0x10(%rbp), %rax
movl %ecx, 0x18(%rax)
jmp 0x5105
cmpl $0x0, -0xb4(%rbp)
je 0x51d2
movl -0xb4(%rbp), %ecx
movq -0x10(%rbp), %rax
movq (%rax), %rax
movl %ecx, 0x78(%rax)
movq -0x10(%rbp), %rax
movq (%rax), %rax
cmpl $0x3, 0x78(%rax)
jb 0x518a
movq -0x10(%rbp), %rax
movq (%rax), %rax
cmpl $0x1, 0x74(%rax)
je 0x516a
movq -0x10(%rbp), %rax
movq (%rax), %rax
cmpl $0x7, 0x74(%rax)
jne 0x518a
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq 0x8(%rax), %rdx
leaq 0xca6d(%rip), %rdi      # 0x11bc8
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
callq 0x60a0
cmpl $0x0, %eax
jne 0x518a
movq -0x10(%rbp), %rax
movl 0x10(%rax), %ecx
xorl %eax, %eax
movl %eax, %edi
leaq 0xa59a(%rip), %rsi      # 0xf716
leaq 0xbc0e(%rip), %rdx      # 0x10d91
movb $0x0, %al
callq 0x2e50
movq -0x10(%rbp), %rax
movq (%rax), %rax
cmpl $0x2, 0x78(%rax)
jne 0x51d0
movq -0x10(%rbp), %rax
cmpq $0x0, 0x8(%rax)
je 0x51d0
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rax
cmpl $0x2, 0x78(%rax)
je 0x51d0
movq -0x10(%rbp), %rax
movl 0x10(%rax), %ecx
xorl %eax, %eax
movl %eax, %edi
leaq 0xa554(%rip), %rsi      # 0xf716
leaq 0xbc2f(%rip), %rdx      # 0x10df8
movb $0x0, %al
callq 0x2e50
jmp 0x51d2
movq -0x10(%rbp), %rax
movq (%rax), %rax
cmpl $0x2, 0x74(%rax)
jne 0x5258
movq -0x10(%rbp), %rax
movq (%rax), %rax
cmpl $0x2, 0x78(%rax)
jne 0x5258
movq -0x10(%rbp), %rax
movq (%rax), %rax
cmpl $0x0, 0x70(%rax)
jne 0x521b
movq -0x10(%rbp), %rax
movl 0x10(%rax), %ecx
xorl %eax, %eax
movl %eax, %edi
leaq 0xa50b(%rip), %rsi      # 0xf716
leaq 0xbc40(%rip), %rdx      # 0x10e52
movb $0x0, %al
callq 0x2e50
jmp 0x5256
movq -0x10(%rbp), %rax
movq (%rax), %rax
cmpl $0x0, 0x6c(%rax)
je 0x5254
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq 0x20(%rax), %rcx
movq -0x10(%rbp), %rax
movl 0x10(%rax), %r8d
xorl %eax, %eax
movl %eax, %edi
leaq 0xa4d0(%rip), %rsi      # 0xf716
leaq 0xbc48(%rip), %rdx      # 0x10e95
movb $0x0, %al
callq 0x2e50
jmp 0x5256
jmp 0x5258
movq -0x10(%rbp), %rax
movq (%rax), %rax
cmpl $0x1, 0x74(%rax)
jne 0x528a
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rcx
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq %rcx, 0x80(%rax)
movq -0x10(%rbp), %rax
movq (%rax), %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x8(%rax)
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x140, %rsp            # imm = 0x140
popq %rbp
retq
nopl (%rax)