// File: /workspace/github_c_makefile_star2_O3/jsummers[P]deark/src/deark-user.c
// Function: de_run
int de_run(deark *c)
{
	dbuf *orig_ifile = NULL;
	dbuf *subfile = NULL;
	i64 subfile_size;
	struct deark_module_info *module_to_use = NULL;
	int module_was_autodetected = 0;
	int moddisp;
	int subdirs_opt;
	int keepdirentries_opt;
	int tmp_opt;
	de_module_params *mparams = NULL;
	de_ucstring *friendly_infn = NULL;

	if(c->serious_error_flag) goto done;

	if(c->modhelp_req && c->input_format_req) {
		do_modhelp(c);
		goto done;
	}

	if(c->extrlist_filename) {
		open_extrlist(c);
		if(c->serious_error_flag) goto done;
	}

	friendly_infn = ucstring_create(c);

	if(c->input_style==DE_INPUTSTYLE_STDIN) {
		ucstring_append_sz(friendly_infn, "[stdin]", DE_ENCODING_LATIN1);
	}
	else if(c->input_filename) {
		ucstring_append_sz(friendly_infn, c->input_filename, DE_ENCODING_UTF8);
	}
	else {
		de_internal_err_nonfatal(c, "Input file not set");
		c->serious_error_flag = 1;
		goto done;
	}

	de_register_modules(c);

	if(c->input_format_req) {
		module_to_use = de_get_module_by_id(c, c->input_format_req);
		if(!module_to_use) {
			de_err(c, "Unknown module \"%s\"", c->input_format_req);
			c->serious_error_flag = 1;
			goto done;
		}
	}

	if(c->slice_start_req_special!=0) {
		ucstring_append_sz(friendly_infn, "[special]", DE_ENCODING_LATIN1);
	}
	else if(c->slice_size_req_valid) {
		ucstring_printf(friendly_infn, DE_ENCODING_LATIN1, "[%"I64_FMT",%"I64_FMT"]",
			c->slice_start_req, c->slice_size_req);
	}
	else if(c->slice_start_req) {
		ucstring_printf(friendly_infn, DE_ENCODING_LATIN1, "[%"I64_FMT"]", c->slice_start_req);
	}
	if(c->mp_data && c->mp_data->count>0) {
		ucstring_printf(friendly_infn, DE_ENCODING_LATIN1, " (+%d more file%s)",
			c->mp_data->count, (c->mp_data->count==1 ? "" : "s"));
	}
	de_dbg(c, "Input file: %s", ucstring_getpsz_d(friendly_infn));

	if(c->input_style==DE_INPUTSTYLE_STDIN) {
		orig_ifile = dbuf_open_input_stdin(c);
	}
	else {
		orig_ifile = dbuf_open_input_file(c, c->input_filename);

		if(orig_ifile && orig_ifile->btype==DBUF_TYPE_FIFO) {
			// Only now do we know that the input "file" is a named pipe.
			// Set a flag to remember that the input filename does not
			// reflect the file format.
			c->suppress_detection_by_filename = 1;
		}
	}
	if(!orig_ifile) {
		goto done;
	}

	c->infile = orig_ifile;

	if(c->slice_start_req_special==1) {
		if(!do_special_overlay_startpos(c)) {
			de_err(c, "File not compatible with \"-start overlay\"");
			goto done;
		}
	}

	// If we are only supposed to look at a segment of the original file,
	// do that by creating a child dbuf, using dbuf_open_input_subfile().
	if(c->slice_start_req!=0 || c->slice_size_req_valid) {
		if(c->slice_start_req<0 || c->slice_size_req<0 ||
			(c->slice_start_req+c->slice_size_req > c->infile->len))
		{
			de_err(c, "File not compatible with given -start/-size options");
			goto done;
		}

		if(c->slice_size_req_valid)
			subfile_size = c->slice_size_req;
		else
			subfile_size = c->infile->len - c->slice_start_req;
		subfile = dbuf_open_input_subfile(c->infile, c->slice_start_req, subfile_size);
		c->infile = subfile;
	}

	if(!module_to_use) {
		int errflag;

		module_to_use = detect_module_for_file(c, &errflag);
		if(errflag) goto done;
		module_was_autodetected = 1;
	}

	if(!module_to_use) {
		if(c->infile->len==0)
			de_err(c, "Unknown or unsupported file format (empty file)");
		else
			de_err(c, "Unknown or unsupported file format");
		goto done;
	}

	if(c->modhelp_req && module_was_autodetected &&
		module_to_use->unique_id!=1) // id 1 == "unsupported"
	{
		do_modhelp_internal(c, module_to_use);
		goto done;
	}

	de_info(c, "Module: %s", module_to_use->id);

	if(c->mp_data && c->mp_data->count &&
		!(module_to_use->flags&DE_MODFLAG_MULTIPART))
	{
		de_err(c, "The %s module does not support multiple input files",
			module_to_use->id);
		c->serious_error_flag = 1;
		goto done;
	}

	if(module_was_autodetected && (module_to_use->flags&DE_MODFLAG_SECURITYWARNING)) {
		de_err(c, "The %s module has not been audited for security. There is a "
			"greater than average chance that it is unsafe to use with untrusted "
			"input files. Use \"-m %s\" to confirm that you want to use it.",
			module_to_use->id, module_to_use->id);
		c->serious_error_flag = 1;
		goto done;
	}

	if(module_was_autodetected && (module_to_use->flags&DE_MODFLAG_WARNPARSEONLY)) {
		de_warn(c, "The %s module can parse files, but does not generally support "
			"extracting data.", module_to_use->id);
	}
	if(module_to_use->flags&DE_MODFLAG_NONWORKING) {
		de_warn(c, "The %s module is considered to be incomplete, and may "
			"not work properly. Caveat emptor.",
			module_to_use->id);
	}

	if(c->identify_only) {
		// Stop here, unless we're using the "unsupported" module.
		if(module_to_use->unique_id!=1) {
			goto done;
		}
	}

	de_dbg2(c, "file size: %" I64_FMT "", c->infile->len);

	if(c->output_style==DE_OUTPUTSTYLE_ARCHIVE) {
		subdirs_opt = de_get_ext_option_bool(c, "archive:subdirs", -1);
		if(subdirs_opt<0) {
			// By default, for archive output, enable subdirs unless -o was used.
			if(!c->base_output_filename) {
				c->allow_subdirs = 1;
			}
		}
		else {
			c->allow_subdirs = subdirs_opt?1:0;
		}
	}

	keepdirentries_opt = de_get_ext_option_bool(c, "keepdirentries", -1);
	if(keepdirentries_opt<0) {
		// By default, only keep dir entries if there is some way that
		// files can be present in such a subdir.
		c->keep_dir_entries = (u8)(
			(c->output_style==DE_OUTPUTSTYLE_ARCHIVE) &&
			c->allow_subdirs &&
			(!c->base_output_filename));
	}
	else {
		c->keep_dir_entries = keepdirentries_opt?1:0;
	}

	if(c->output_style==DE_OUTPUTSTYLE_ARCHIVE) {
		const char *s_opt;

		s_opt = de_get_ext_option(c, "archive:timestamp");
		if(s_opt) {
			c->reproducible_output = 1;
			de_unix_time_to_timestamp(de_atoi64(s_opt), &c->reproducible_timestamp, 0x1);
			if(!c->reproducible_timestamp.is_valid) {
				// Timestamp out of range? Note: Supported range is
				//  -11644473599 ( 1601-01-01 00:00:01) through
				//  910692730085 (30828-09-14 02:48:05)
				c->reproducible_output = 0;
			}
		}
		else {
			if(de_get_ext_option(c, "archive:repro")) {
				c->reproducible_output = 1;
			}
		}
	}

	if(c->output_style==DE_OUTPUTSTYLE_DIRECT &&
		c->max_output_files > DE_DEFAULT_MAX_OUTPUT_FILES &&
		!c->list_mode && !c->user_set_max_output_files)
	{
		c->max_output_files = DE_DEFAULT_MAX_OUTPUT_FILES;
	}

	if(de_get_ext_option_bool(c, "oinfo", 0)) {
		c->enable_oinfo = 1;
	}

	tmp_opt = de_get_ext_option_bool(c, "wbuffer", -1);
	if(tmp_opt>0) {
		// For testing(?), enable wbuffer feature automatically in some cases.
		c->enable_wbuffer_test = 1;
	}
	else if(tmp_opt==0) {
		// Always disable wbuffer, even if a module wants to use it.
		c->disable_wbuffer = 1;
	}

	// If we're writing to a zip file, we normally defer creating that zip file
	// until we find a file to extract, so that we never create a zip file with
	// no member files.
	// But if the zip "file" is going to stdout, we'll make sure we produce zip
	// output, even if it has no member files.
	if(c->output_style==DE_OUTPUTSTYLE_ARCHIVE && c->archive_to_stdout) {
		if(!de_archive_initialize(c)) {
			goto done;
		}
	}

	if(c->list_mode) {
		if(de_get_ext_option_bool(c, "list:fileid", 0)) {
			c->list_mode_include_file_id = 1;
		}
	}

	if(c->modcodes_req) {
		if(!mparams)
			mparams = de_malloc(c, sizeof(de_module_params));
		// This is a hack, mainly for developer use. It lets the user set the
		// "module codes" string from the command line, so that some modules
		// can be run in special modes. For example, you can run the psd module
		// in its "tagged blocks" mode. (If that turns out to be useful, though,
		// it would be better to make it available via an "-opt" option, or
		// even a new module.)
		mparams->in_params.codes = c->modcodes_req;
	}

	if(module_was_autodetected)
		moddisp = DE_MODDISP_AUTODETECT;
	else
		moddisp = DE_MODDISP_EXPLICIT;

	if(!de_run_module(c, module_to_use, mparams, moddisp)) {
		goto done;
	}

	// The DE_MODFLAG_NOEXTRACT flag means the module is not expected to extract
	// any files.
	if(c->num_files_extracted==0 && c->error_count==0 &&
		!(module_to_use->flags&DE_MODFLAG_NOEXTRACT))
	{
		de_info(c, "No files found to extract!");
	}

done:
	if(c->extrlist_dbuf) { dbuf_close(c->extrlist_dbuf); c->extrlist_dbuf=NULL; }
	ucstring_destroy(friendly_infn);
	if(subfile) dbuf_close(subfile);
	if(orig_ifile) dbuf_close(orig_ifile);
	c->infile = NULL;
	de_free(c, mparams);
	return c->serious_error_flag ? 0 : 1;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rdi, %rbx
cmpb $0x0, 0x4c(%rdi)
je 0x108190
xorl %r12d, %r12d
xorl %r15d, %r15d
xorl %ebp, %ebp
xorl %r14d, %r14d
movq 0x148(%rbx), %rdi
testq %rdi, %rdi
je 0x108143
callq 0xf052b
movq $0x0, 0x148(%rbx)
movq %r14, %rdi
callq 0xf6753
testq %r12, %r12
je 0x108158
movq %r12, %rdi
callq 0xf052b
testq %r15, %r15
je 0x108165
movq %r15, %rdi
callq 0xf052b
movq $0x0, 0x18(%rbx)
movq %rbx, %rdi
movq %rbp, %rsi
callq 0xe8be2
xorl %eax, %eax
cmpb $0x0, 0x4c(%rbx)
sete %al
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
cmpb $0x0, 0xf9(%rbx)
je 0x1081ba
cmpq $0x0, 0x58(%rbx)
je 0x1081ba
movq 0x1a0(%rbx), %rax
testq %rax, %rax
je 0x108291
movq %rbx, %rdi
callq *%rax
jmp 0x1082a2
cmpq $0x0, 0x168(%rbx)
je 0x1081d2
cmpq $0x0, 0x148(%rbx)
je 0x10830f
movq %rbx, %rdi
callq 0xf6410
movq %rax, %r14
cmpl $0x1, 0x84(%rbx)
jne 0x1081f7
leaq 0x4429c(%rip), %rsi     # 0x14c489
movq %r14, %rdi
movl $0x5, %edx
jmp 0x10820c
movq 0x50(%rbx), %rsi
testq %rsi, %rsi
je 0x108376
movq %r14, %rdi
movl $0x2, %edx
callq 0xf65e3
movq 0x1a0(%rbx), %rax
testq %rax, %rax
je 0x108224
movq %rbx, %rdi
callq *%rax
jmp 0x108235
leaq 0x44243(%rip), %rsi     # 0x14c46e
movq %rbx, %rdi
xorl %eax, %eax
callq 0xe9544
movq 0x58(%rbx), %rsi
testq %rsi, %rsi
je 0x10826b
movq %rbx, %rdi
callq 0xe9936
movq %rax, %r13
testq %rax, %rax
jne 0x10826e
movq 0x58(%rbx), %rdx
leaq 0x4424b(%rip), %rsi     # 0x14c4a4
xorl %r12d, %r12d
movq %rbx, %rdi
xorl %eax, %eax
callq 0xe9295
jmp 0x10838a
xorl %r13d, %r13d
cmpb $0x0, 0x78(%rbx)
je 0x108350
leaq 0x44239(%rip), %rsi     # 0x14c4b8
movq %r14, %rdi
movl $0x5, %edx
callq 0xf65e3
jmp 0x1083ae
leaq 0x441d6(%rip), %rsi     # 0x14c46e
movq %rbx, %rdi
xorl %eax, %eax
callq 0xe9544
movq 0x58(%rbx), %rsi
movq %rbx, %rdi
callq 0xe9936
movq 0x58(%rbx), %r15
testq %rax, %rax
je 0x1082f3
movq %rax, %r14
movq (%rax), %r12
movq %r15, %rdi
movq %r12, %rsi
callq 0x181a0
testl %eax, %eax
je 0x1082e3
leaq 0x444f1(%rip), %rsi     # 0x14c7c4
movq %rbx, %rdi
movq %r15, %rdx
movq %r12, %rcx
xorl %eax, %eax
callq 0xe9461
movq %rbx, %rdi
movq %r14, %rsi
callq 0x108a0f
jmp 0x10811c
leaq 0x441aa(%rip), %rsi     # 0x14c4a4
xorl %r12d, %r12d
movq %rbx, %rdi
movq %r15, %rdx
xorl %eax, %eax
callq 0xe9295
jmp 0x10811f
leaq 0x444cf(%rip), %rsi     # 0x14c7e5
movq %rbx, %rdi
callq 0xe9b74
xorl %ecx, %ecx
testq %rax, %rax
setne %cl
movq 0x168(%rbx), %rsi
movq %rbx, %rdi
movl $0x2, %edx
callq 0xf074a
movq %rax, 0x148(%rbx)
cmpb $0x0, 0x4c(%rbx)
jne 0x10811c
jmp 0x1081d2
cmpb $0x0, 0x79(%rbx)
movq 0x68(%rbx), %rcx
je 0x108393
movq 0x70(%rbx), %r8
leaq 0x4415d(%rip), %rdx     # 0x14c4c2
movq %r14, %rdi
movl $0x5, %esi
xorl %eax, %eax
callq 0xf6653
jmp 0x1083ae
leaq 0x44114(%rip), %rsi     # 0x14c491
xorl %r12d, %r12d
movq %rbx, %rdi
xorl %eax, %eax
callq 0xe9640
movb $0x1, 0x4c(%rbx)
jmp 0x1084e6
testq %rcx, %rcx
je 0x1083ae
leaq 0x11d87(%rip), %rdx     # 0x11a126
movq %r14, %rdi
movl $0x5, %esi
xorl %eax, %eax
callq 0xf6653
movq 0x30(%rbx), %rax
testq %rax, %rax
je 0x1083e8
movl (%rax), %ecx
testl %ecx, %ecx
jle 0x1083e8
cmpl $0x1, %ecx
leaq 0x3cce9(%rip), %rax     # 0x1450b0
leaq 0xc992(%rip), %r8       # 0x114d60
cmoveq %rax, %r8
leaq 0x440f3(%rip), %rdx     # 0x14c4cc
movq %r14, %rdi
movl $0x5, %esi
xorl %eax, %eax
callq 0xf6653
movq %r14, %rdi
callq 0xf70f6
leaq 0x440e8(%rip), %rsi     # 0x14c4df
movq %rbx, %rdi
movq %rax, %rdx
xorl %eax, %eax
callq 0xe8617
cmpl $0x1, 0x84(%rbx)
jne 0x108422
movq %rbx, %rdi
callq 0xf1346
movq %rax, %r15
testq %rax, %rax
jne 0x108443
jmp 0x1084e3
movq 0x50(%rbx), %rsi
movq %rbx, %rdi
callq 0xf1114
testq %rax, %rax
je 0x1084e3
movq %rax, %r15
cmpl $0x7, (%rax)
jne 0x108443
movb $0x1, 0x7a(%rbx)
movq %r15, 0x18(%rbx)
cmpb $0x1, 0x78(%rbx)
jne 0x1084eb
leaq 0x6(%rsp), %r12
movl $0x2, %ecx
movq %r15, %rdi
movq %r12, %rsi
xorl %edx, %edx
callq 0xee8d4
movb (%r12), %al
movb 0x1(%r12), %cl
movl %eax, %edx
xorb $0x4d, %dl
movl %ecx, %esi
xorb $0x5a, %sil
orb %dl, %sil
je 0x10848e
xorb $0x5a, %al
xorb $0x4d, %cl
orb %al, %cl
jne 0x108527
movq 0x18(%rbx), %rdi
movl $0x2, %esi
callq 0xeebc8
movq %rax, %rbp
movq 0x18(%rbx), %rdi
movl $0x4, %esi
callq 0xeebc8
movq %rax, %r12
andl $0x7ff, %r12d           # imm = 0x7FF
testq %rbp, %rbp
je 0x1084f1
cmpq $0x200, %rbp            # imm = 0x200
setl %al
testq %r12, %r12
setne %cl
andb %al, %cl
cmpb $0x1, %cl
jne 0x108527
shll $0x9, %r12d
addq %rbp, %r12
addq $-0x200, %r12           # imm = 0xFE00
jmp 0x1084f5
xorl %r12d, %r12d
xorl %r15d, %r15d
jmp 0x108564
movq 0x68(%rbx), %r12
jmp 0x10851e
shll $0x9, %r12d
movq 0x18(%rbx), %rax
movq 0x18(%rax), %rcx
subq %r12, %rcx
js 0x108527
leaq 0x442ec(%rip), %rsi     # 0x14c7f5
movq %rbx, %rdi
movq %r12, %rdx
xorl %eax, %eax
callq 0xe87e4
movq %r12, 0x68(%rbx)
movb $0x1, 0x7a(%rbx)
testq %r12, %r12
je 0x108530
jns 0x108536
jmp 0x108550
leaq 0x43fc0(%rip), %rsi     # 0x14c4ee
jmp 0x108557
cmpb $0x0, 0x79(%rbx)
je 0x108587
movq 0x70(%rbx), %rdx
testq %rdx, %rdx
js 0x108550
leaq (%rdx,%r12), %rcx
movq 0x18(%rbx), %rdi
movq 0x18(%rdi), %rax
cmpq %rax, %rcx
jle 0x10856b
leaq 0x43fc1(%rip), %rsi     # 0x14c518
xorl %r12d, %r12d
movq %rbx, %rdi
xorl %eax, %eax
callq 0xe9295
xorl %ebp, %ebp
jmp 0x108127
subq %r12, %rax
cmpb $0x0, 0x79(%rbx)
cmoveq %rax, %rdx
movq %r12, %rsi
callq 0xf1388
movq %rax, %r12
movq %rax, 0x18(%rbx)
jmp 0x10858a
xorl %r12d, %r12d
movq %r13, %rbp
testq %r13, %r13
je 0x10865f
movq (%rbp), %rdx
leaq 0x43ffe(%rip), %rsi     # 0x14c59f
movq %rbx, %rdi
xorl %eax, %eax
callq 0xe9393
movq 0x30(%rbx), %rax
testq %rax, %rax
je 0x1085db
cmpl $0x0, (%rax)
je 0x1085db
testb $0x40, 0x30(%rbp)
jne 0x1085db
movq (%rbp), %rdx
leaq 0x43fe0(%rip), %rsi     # 0x14c5aa
xorl %ebp, %ebp
movq %rbx, %rdi
xorl %eax, %eax
callq 0xe9295
jmp 0x1086ef
testq %r13, %r13
je 0x1086ac
testb $0x2, 0x30(%rbp)
je 0x1085ff
movq (%rbp), %rdx
leaq 0x440f5(%rip), %rsi     # 0x14c6ea
movq %rbx, %rdi
xorl %eax, %eax
callq 0xe8faa
cmpb $0x0, 0xf8(%rbx)
je 0x108612
cmpl $0x1, 0x34(%rbp)
jne 0x108564
movq 0x18(%rbx), %rax
movq 0x18(%rax), %rdx
leaq 0xe0dd(%rip), %rsi      # 0x1166fe
movq %rbx, %rdi
xorl %eax, %eax
callq 0xe87e4
cmpl $0x1, 0x7c(%rbx)
jne 0x108706
leaq 0x44106(%rip), %rsi     # 0x14c742
movq %rbx, %rdi
movl $0xffffffff, %edx       # imm = 0xFFFFFFFF
callq 0xe9bd0
testl %eax, %eax
js 0x1086f8
setne %al
movb %al, 0x89(%rbx)
jmp 0x108706
leaq 0x14(%rsp), %rbp
movq %rbx, %rdi
movq %rbp, %rsi
callq 0x10892a
cmpl $0x0, (%rbp)
jne 0x108564
testq %rax, %rax
je 0x1088f7
movq %rax, %rbp
cmpb $0x0, 0xf9(%rbx)
je 0x108596
cmpl $0x1, 0x34(%rbp)
je 0x108596
movq %rbx, %rdi
movq %rbp, %rsi
callq 0x108a0f
jmp 0x108564
movl 0x30(%rbp), %eax
testb $0x8, %al
jne 0x1086d5
testb $0x20, %al
je 0x1085e4
movq (%rbp), %rdx
leaq 0x43fd5(%rip), %rsi     # 0x14c69b
movq %rbx, %rdi
xorl %eax, %eax
callq 0xe8faa
jmp 0x1085e4
movq (%rbp), %rcx
leaq 0x43efe(%rip), %rsi     # 0x14c5de
xorl %ebp, %ebp
movq %rbx, %rdi
movq %rcx, %rdx
xorl %eax, %eax
callq 0xe9295
movb $0x1, 0x4c(%rbx)
jmp 0x108127
cmpq $0x0, 0x150(%rbx)
je 0x10890b
leaq 0x44045(%rip), %rsi     # 0x14c752
movq %rbx, %rdi
movl $0xffffffff, %edx       # imm = 0xFFFFFFFF
callq 0xe9bd0
testl %eax, %eax
js 0x10872a
setne 0xcf(%rbx)
movl 0x7c(%rbx), %eax
jmp 0x108750
movl 0x7c(%rbx), %eax
cmpl $0x1, %eax
jne 0x108748
cmpb $0x0, 0x89(%rbx)
je 0x108748
cmpq $0x0, 0x150(%rbx)
sete %cl
jmp 0x10874a
xorl %ecx, %ecx
movb %cl, 0xcf(%rbx)
cmpl $0x1, %eax
jne 0x1087bc
leaq 0x44005(%rip), %rsi     # 0x14c761
movq %rbx, %rdi
callq 0xe9b74
testq %rax, %rax
je 0x10879e
movb $0x1, 0xdf(%rbx)
movq %rax, %rdi
callq 0xe9c2f
leaq 0xe0(%rbx), %rsi
movq %rax, %rdi
movl $0x1, %edx
callq 0xea7f5
cmpb $0x0, 0xe0(%rbx)
jne 0x1087b9
movb $0x0, 0xdf(%rbx)
jmp 0x1087b9
leaq 0x43fce(%rip), %rsi     # 0x14c773
movq %rbx, %rdi
callq 0xe9b74
testq %rax, %rax
je 0x1087b9
movb $0x1, 0xdf(%rbx)
movl 0x7c(%rbx), %eax
testl %eax, %eax
jne 0x1087e8
cmpl $0x3e9, 0x9c(%rbx)      # imm = 0x3E9
jl 0x1087e8
cmpb $0x0, 0x94(%rbx)
jne 0x1087e8
cmpb $0x0, 0xa0(%rbx)
jne 0x1087e8
movl $0x3e8, 0x9c(%rbx)      # imm = 0x3E8
leaq 0x7ddc(%rip), %rsi      # 0x1105cb
movq %rbx, %rdi
xorl %edx, %edx
callq 0xe9bd0
testl %eax, %eax
je 0x108804
movb $0x1, 0x96(%rbx)
leaq 0x43f76(%rip), %rsi     # 0x14c781
movq %rbx, %rdi
movl $0xffffffff, %edx       # imm = 0xFFFFFFFF
callq 0xe9bd0
testl %eax, %eax
jle 0x108825
movb $0x1, 0x12b(%rbx)
jmp 0x10882e
jne 0x10882e
movb $0x1, 0x12c(%rbx)
cmpl $0x1, 0x7c(%rbx)
jne 0x10884d
cmpb $0x0, 0x88(%rbx)
je 0x10884d
movq %rbx, %rdi
callq 0xeba1d
testl %eax, %eax
je 0x108564
cmpb $0x0, 0x94(%rbx)
je 0x108872
leaq 0x43f2c(%rip), %rsi     # 0x14c789
movq %rbx, %rdi
xorl %edx, %edx
callq 0xe9bd0
testl %eax, %eax
je 0x108872
movb $0x1, 0x95(%rbx)
movq %rbp, 0x8(%rsp)
cmpq $0x0, 0x60(%rbx)
je 0x108898
movl $0x70, %esi
movq %rbx, %rdi
callq 0xe8b2b
movq %rax, %rbp
movq 0x60(%rbx), %rax
movq %rax, (%rbp)
jmp 0x10889a
xorl %ebp, %ebp
cmpq $0x1, %r13
movl $0x2, %ecx
sbbl $0x0, %ecx
movq %rbx, %rdi
movq 0x8(%rsp), %rsi
movq %rbp, %rdx
callq 0xe995a
testl %eax, %eax
je 0x108127
cmpl $0x0, 0x3c(%rbx)
jne 0x108127
cmpl $0x0, 0x48(%rbx)
jne 0x108127
movq 0x8(%rsp), %rax
testb $0x4, 0x30(%rax)
jne 0x108127
leaq 0x43ead(%rip), %rsi     # 0x14c795
movq %rbx, %rdi
xorl %eax, %eax
callq 0xe9393
jmp 0x108127
movq 0x18(%rbx), %rax
cmpq $0x0, 0x18(%rax)
je 0x108912
leaq 0x43c73(%rip), %rsi     # 0x14c57c
jmp 0x108919
movb $0x1, %al
jmp 0x108654
leaq 0x43c33(%rip), %rsi     # 0x14c54c
xorl %ebp, %ebp
movq %rbx, %rdi
xorl %eax, %eax
callq 0xe9295
jmp 0x108127