// File: /workspace/github_c_makefile_star2_O1/nurse[P]nkf/nkf.c
// Function: module_connection
static int
module_connection(void)
{
    if (input_encoding) set_input_encoding(input_encoding);
    if (!output_encoding) {
	output_encoding = nkf_default_encoding();
    }
    if (!output_encoding) {
	if (noout_f || guess_f) output_encoding = nkf_enc_from_index(ISO_2022_JP);
	else return -1;
    }
    set_output_encoding(output_encoding);
    oconv = nkf_enc_to_oconv(output_encoding);
    o_putc = std_putc;
    if (nkf_enc_unicode_p(output_encoding))
	output_mode = UTF_8;

    if (x0201_f == NKF_UNSPECIFIED) {
	x0201_f = X0201_DEFAULT;
    }

    /* replace continuation module, from output side */

    /* output redirection */
#ifdef CHECK_OPTION
    if (noout_f || guess_f){
	o_putc = no_putc;
    }
#endif
    if (mimeout_f) {
	o_mputc = o_putc;
	o_putc = mime_putc;
	if (mimeout_f == TRUE) {
	    o_base64conv = oconv; oconv = base64_conv;
	}
	/* base64_count = 0; */
    }

    if (eolmode_f || guess_f) {
	o_eol_conv = oconv; oconv = eol_conv;
    }
    if (rot_f) {
	o_rot_conv = oconv; oconv = rot_conv;
    }
    if (iso2022jp_f) {
	o_iso2022jp_check_conv = oconv; oconv = iso2022jp_check_conv;
    }
    if (hira_f) {
	o_hira_conv = oconv; oconv = hira_conv;
    }
    if (fold_f) {
	o_fconv = oconv; oconv = fold_conv;
	f_line = 0;
    }
    if (alpha_f || x0201_f) {
	o_zconv = oconv; oconv = z_conv;
    }

    i_getc = std_getc;
    i_ungetc = std_ungetc;
    /* input redirection */
#ifdef INPUT_OPTION
    if (cap_f){
	i_cgetc = i_getc; i_getc = cap_getc;
	i_cungetc = i_ungetc; i_ungetc= cap_ungetc;
    }
    if (url_f){
	i_ugetc = i_getc; i_getc = url_getc;
	i_uungetc = i_ungetc; i_ungetc= url_ungetc;
    }
#endif
#ifdef NUMCHAR_OPTION
    if (numchar_f){
	i_ngetc = i_getc; i_getc = numchar_getc;
	i_nungetc = i_ungetc; i_ungetc= numchar_ungetc;
    }
#endif
#ifdef UNICODE_NORMALIZATION
    if (nfc_f){
	i_nfc_getc = i_getc; i_getc = nfc_getc;
	i_nfc_ungetc = i_ungetc; i_ungetc= nfc_ungetc;
    }
#endif
    if (mime_f && mimebuf_f==FIXED_MIME) {
	i_mgetc = i_getc; i_getc = mime_getc;
	i_mungetc = i_ungetc; i_ungetc = mime_ungetc;
    }
    if (broken_f & 1) {
	i_bgetc = i_getc; i_getc = broken_getc;
	i_bungetc = i_ungetc; i_ungetc = broken_ungetc;
    }
    if (input_encoding) {
	set_iconv(-TRUE, nkf_enc_to_iconv(input_encoding));
    } else {
	set_iconv(FALSE, e_iconv);
    }

    {
	struct input_code *p = input_code_list;
	while (p->name){
	    status_reinit(p++);
	}
    }
    return 0;
}

// Assembly:
movq 0x42d3a(%rip), %rax     # 0x55420
testq %rax, %rax
je 0x12818
movl (%rax), %eax
decl %eax
cmpl $0x21, %eax
ja 0x12818
leaq 0x4acd(%rip), %rcx      # 0x171d0
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movl $0x1, 0x3abce(%rip)     # 0x4d2e4
jmp 0x12818
cmpl $-0x1, 0x3ab8e(%rip)    # 0x4d2b0
jne 0x1272e
movl $0x0, 0x3ab82(%rip)     # 0x4d2b0
movb $0x1, 0x42ccf(%rip)     # 0x55404
movl $0x2, 0x42cc9(%rip)     # 0x55408
jmp 0x12818
movl $0x2, 0x3ab96(%rip)     # 0x4d2e4
jmp 0x12818
movb $0x1, %al
movb %al, 0x3ac5d(%rip)      # 0x4d3b8
movb %al, 0x3ac5b(%rip)      # 0x4d3bc
jmp 0x12818
movb $0x1, 0x3ac4f(%rip)     # 0x4d3bc
movb $0x0, 0x42c90(%rip)     # 0x55404
jmp 0x12818
movb $0x1, 0x3ac3c(%rip)     # 0x4d3bc
movb $0x0, 0x42c7d(%rip)     # 0x55404
cmpl $0x1, 0x3ab32(%rip)     # 0x4d2c0
jne 0x12818
movl $0x0, 0x3ab22(%rip)     # 0x4d2c0
jmp 0x12818
movb $0x1, 0x42c5d(%rip)     # 0x55404
movl $0x3, 0x42c57(%rip)     # 0x55408
jmp 0x12818
movb $0x1, 0x42da6(%rip)     # 0x55560
jmp 0x12818
movb $0x1, 0x42da1(%rip)     # 0x55564
jmp 0x12818
cmpl $-0x1, 0x3aae4(%rip)    # 0x4d2b0
jne 0x127d8
movl $0x0, 0x3aad8(%rip)     # 0x4d2b0
movb $0x0, 0x42c25(%rip)     # 0x55404
movl $0x1, 0x42c1f(%rip)     # 0x55408
jmp 0x12818
movb $0x1, 0x3abc6(%rip)     # 0x4d3b8
jmp 0x12818
cmpl $-0x1, 0x3aab5(%rip)    # 0x4d2b0
jne 0x12807
movl $0x0, 0x3aaa9(%rip)     # 0x4d2b0
movb $0x0, 0x42bf6(%rip)     # 0x55404
movl $0x0, 0x42bf0(%rip)     # 0x55408
pushq %rax
cmpq $0x0, 0x42d27(%rip)     # 0x55548
jne 0x1282f
callq 0x1262c
movq %rax, 0x42d19(%rip)     # 0x55548
cmpq $0x0, 0x42d11(%rip)     # 0x55548
jne 0x12862
cmpb $0x0, 0x42d1c(%rip)     # 0x5555c
jne 0x12854
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
cmpl $0x0, 0x3ab62(%rip)     # 0x4d3b0
je 0x12d5e
leaq 0x33ff5(%rip), %rax     # 0x46850
movq %rax, 0x42ce6(%rip)     # 0x55548
movq 0x42cdf(%rip), %rax     # 0x55548
movl (%rax), %ecx
addl $-0x2, %ecx
cmpl $0x20, %ecx
ja 0x129c3
leaq 0x49da(%rip), %rdx      # 0x17258
movslq (%rdx,%rcx,4), %rcx
addq %rdx, %rcx
jmpq *%rcx
movb $0x1, 0x42ca2(%rip)     # 0x55530
jmp 0x129c3
movb $0x1, %cl
movb %cl, 0x3ab1d(%rip)      # 0x4d3b8
movb %cl, 0x3ab1b(%rip)      # 0x4d3bc
jmp 0x1296b
movb $0x1, %cl
movb %cl, 0x42c86(%rip)      # 0x55534
movb %cl, 0x42c7c(%rip)      # 0x55530
jmp 0x129c3
movb $0x1, 0x42c74(%rip)     # 0x55534
movb $0x0, 0x42c69(%rip)     # 0x55530
jmp 0x129c3
movb $0x1, 0x3aae9(%rip)     # 0x4d3bc
jmp 0x1296b
cmpl $-0x1, 0x3a9d1(%rip)    # 0x4d2b0
jne 0x128eb
movl $0x0, 0x3a9c5(%rip)     # 0x4d2b0
cmpl $0x1, 0x3a9ce(%rip)     # 0x4d2c0
jne 0x129b9
movl $0x0, 0x3a9be(%rip)     # 0x4d2c0
jmp 0x129b9
cmpl $-0x1, 0x3a9a2(%rip)    # 0x4d2b0
jne 0x1291a
movl $0x0, 0x3a996(%rip)     # 0x4d2b0
movb $0x1, 0x3aa97(%rip)     # 0x4d3b8
movl $0x1, 0x42add(%rip)     # 0x55408
jmp 0x129c3
movl $0x3, 0x42ace(%rip)     # 0x55408
jmp 0x129c3
movb $0x0, 0x3aa72(%rip)     # 0x4d3b8
jmp 0x1294f
movb $0x1, 0x3aa69(%rip)     # 0x4d3b8
cmpl $0x1, 0x3a96a(%rip)     # 0x4d2c0
jne 0x1299a
movl $0x0, 0x3a95e(%rip)     # 0x4d2c0
jmp 0x1299a
movb $0x1, 0x3aa4d(%rip)     # 0x4d3b8
cmpl $0x1, 0x3a94e(%rip)     # 0x4d2c0
jne 0x129c3
movl $0x0, 0x3a942(%rip)     # 0x4d2c0
jmp 0x129c3
cmpl $-0x1, 0x3a929(%rip)    # 0x4d2b0
jne 0x12993
movl $0x0, 0x3a91d(%rip)     # 0x4d2b0
movb $0x1, 0x3aa1e(%rip)     # 0x4d3b8
movl $0x0, 0x42a64(%rip)     # 0x55408
jmp 0x129c3
cmpl $-0x1, 0x3a903(%rip)    # 0x4d2b0
jne 0x129b9
movl $0x0, 0x3a8f7(%rip)     # 0x4d2b0
movl $0x2, 0x42a45(%rip)     # 0x55408
movq 0x10(%rax), %rcx
movq 0x10(%rcx), %rax
movq %rax, 0x3a8e6(%rip)     # 0x4d2b8
leaq -0xe36(%rip), %rdx      # 0x11ba3
movq %rdx, 0x3a8e8(%rip)     # 0x4d2c8
leaq 0x33e19(%rip), %rdx     # 0x46800
cmpq %rdx, %rcx
je 0x12a04
leaq 0x33ddd(%rip), %rdx     # 0x467d0
cmpq %rdx, %rcx
je 0x12a04
leaq 0x33de9(%rip), %rdx     # 0x467e8
cmpq %rdx, %rcx
jne 0x12a0e
movl $0x15, 0x42a0e(%rip)    # 0x5541c
cmpl $-0x1, 0x3a89b(%rip)    # 0x4d2b0
jne 0x12a21
movl $0x1, 0x3a88f(%rip)     # 0x4d2b0
movl 0x3a989(%rip), %ecx     # 0x4d3b0
testl %ecx, %ecx
setne %dl
orb 0x42b2a(%rip), %dl      # 0x5555c
testb $0x1, %dl
je 0x12a45
leaq 0x322(%rip), %rdx       # 0x12d60
movq %rdx, 0x3a883(%rip)     # 0x4d2c8
movl 0x42b41(%rip), %edx     # 0x5558c
testl %edx, %edx
je 0x12a85
movq 0x3a872(%rip), %rsi     # 0x4d2c8
movq %rsi, 0x3a8eb(%rip)     # 0x4d348
leaq 0x2fd(%rip), %rsi       # 0x12d61
movq %rsi, 0x3a85d(%rip)     # 0x4d2c8
cmpl $0x1, %edx
jne 0x12a85
movq %rax, 0x3a8a1(%rip)     # 0x4d318
leaq 0xc50(%rip), %rax       # 0x136ce
movq %rax, 0x3a833(%rip)     # 0x4d2b8
orl 0x42b09(%rip), %ecx     # 0x55594
je 0x12aa9
movq 0x3a824(%rip), %rax     # 0x4d2b8
movq %rax, 0x3a865(%rip)     # 0x4d300
leaq 0xd92(%rip), %rax       # 0x13834
movq %rax, 0x3a80f(%rip)     # 0x4d2b8
cmpb $0x1, 0x42abc(%rip)     # 0x5556c
jne 0x12ace
movq 0x3a7ff(%rip), %rax     # 0x4d2b8
movq %rax, 0x3a848(%rip)     # 0x4d308
leaq 0xe7f(%rip), %rax       # 0x13946
movq %rax, 0x3a7ea(%rip)     # 0x4d2b8
cmpb $0x1, 0x4292b(%rip)     # 0x55400
jne 0x12af3
movq 0x3a7da(%rip), %rax     # 0x4d2b8
movq %rax, 0x3a83b(%rip)     # 0x4d320
leaq 0xed4(%rip), %rax       # 0x139c0
movq %rax, 0x3a7c5(%rip)     # 0x4d2b8
cmpl $0x0, 0x42a6e(%rip)     # 0x55568
je 0x12b18
movq 0x3a7b5(%rip), %rax     # 0x4d2b8
movq %rax, 0x3a806(%rip)     # 0x4d310
leaq 0xf2e(%rip), %rax       # 0x13a3f
movq %rax, 0x3a7a0(%rip)     # 0x4d2b8
cmpb $0x1, 0x42a59(%rip)     # 0x55578
jne 0x12b47
movq 0x3a790(%rip), %rax     # 0x4d2b8
movq %rax, 0x3a7c9(%rip)     # 0x4d2f8
leaq 0xfe6(%rip), %rax       # 0x13b1c
movq %rax, 0x3a77b(%rip)     # 0x4d2b8
movl $0x0, 0x42aa9(%rip)     # 0x555f0
movl 0x3a763(%rip), %eax     # 0x4d2b0
orl 0x42a1d(%rip), %eax     # 0x55570
je 0x12b71
movq 0x3a75c(%rip), %rax     # 0x4d2b8
movq %rax, 0x3a78d(%rip)     # 0x4d2f0
leaq 0x12ff(%rip), %rax      # 0x13e69
movq %rax, 0x3a747(%rip)     # 0x4d2b8
leaq -0x51d(%rip), %rax      # 0x1265b
movq %rax, 0x3a7a9(%rip)     # 0x4d328
leaq -0x511(%rip), %rax      # 0x12675
movq %rax, 0x3a7a3(%rip)     # 0x4d330
cmpb $0x1, 0x429bc(%rip)     # 0x55550
jne 0x12bb2
leaq 0x1702(%rip), %rax      # 0x1429f
movq %rax, 0x3a784(%rip)     # 0x4d328
leaq 0x170f(%rip), %rax      # 0x142ba
movq %rax, 0x3a77e(%rip)     # 0x4d330
cmpb $0x1, 0x4299b(%rip)     # 0x55554
jne 0x12bf3
movq 0x3a766(%rip), %rax     # 0x4d328
movq %rax, 0x3a7a7(%rip)     # 0x4d370
leaq 0x16ef(%rip), %rax      # 0x142bf
movq %rax, 0x3a751(%rip)     # 0x4d328
movq 0x3a752(%rip), %rax     # 0x4d330
movq %rax, 0x3a793(%rip)     # 0x4d378
leaq 0x16ee(%rip), %rax      # 0x142da
movq %rax, 0x3a73d(%rip)     # 0x4d330
cmpb $0x1, 0x4295e(%rip)     # 0x55558
jne 0x12c34
movq 0x3a725(%rip), %rax     # 0x4d328
movq %rax, 0x3a776(%rip)     # 0x4d380
leaq 0x16d2(%rip), %rax      # 0x142e3
movq %rax, 0x3a710(%rip)     # 0x4d328
movq 0x3a711(%rip), %rax     # 0x4d330
movq %rax, 0x3a762(%rip)     # 0x4d388
leaq 0x1826(%rip), %rax      # 0x14453
movq %rax, 0x3a6fc(%rip)     # 0x4d330
cmpb $0x1, 0x42925(%rip)     # 0x55560
jne 0x12c75
movq 0x3a6e4(%rip), %rax     # 0x4d328
movq %rax, 0x3a745(%rip)     # 0x4d390
leaq 0x180a(%rip), %rax      # 0x1445c
movq %rax, 0x3a6cf(%rip)     # 0x4d328
movq 0x3a6d0(%rip), %rax     # 0x4d330
movq %rax, 0x3a731(%rip)     # 0x4d398
leaq 0x1a00(%rip), %rax      # 0x1466e
movq %rax, 0x3a6bb(%rip)     # 0x4d330
cmpl $0x0, 0x3a624(%rip)     # 0x4d2a0
je 0x12cbf
cmpl $0x7, 0x428ff(%rip)     # 0x55584
jne 0x12cbf
movq 0x3a69a(%rip), %rax     # 0x4d328
movq %rax, 0x3a6bb(%rip)     # 0x4d350
leaq 0x19db(%rip), %rax      # 0x14677
movq %rax, 0x3a685(%rip)     # 0x4d328
movq 0x3a686(%rip), %rax     # 0x4d330
movq %rax, 0x3a6a7(%rip)     # 0x4d358
leaq 0x21fd(%rip), %rax      # 0x14eb5
movq %rax, 0x3a671(%rip)     # 0x4d330
testb $0x1, 0x428ca(%rip)     # 0x55590
je 0x12d00
movq 0x3a659(%rip), %rax     # 0x4d328
movq %rax, 0x3a662(%rip)     # 0x4d338
leaq 0x21f9(%rip), %rax      # 0x14ed6
movq %rax, 0x3a644(%rip)     # 0x4d328
movq 0x3a645(%rip), %rax     # 0x4d330
movq %rax, 0x3a64e(%rip)     # 0x4d340
leaq 0x2354(%rip), %rax      # 0x1504d
movq %rax, 0x3a630(%rip)     # 0x4d330
movq 0x42719(%rip), %rax     # 0x55420
testq %rax, %rax
je 0x12d1b
movq 0x10(%rax), %rax
movq 0x8(%rax), %rsi
movl $0xffffffff, %edi       # imm = 0xFFFFFFFF
jmp 0x12d24
leaq -0x67f6(%rip), %rsi     # 0xc52c
xorl %edi, %edi
callq 0x11bad
cmpq $0x0, 0x3a41f(%rip)     # 0x4d150
je 0x12d5c
leaq 0x3a41e(%rip), %rdx     # 0x4d158
movabsq $0x8000000000, %rcx     # imm = 0x8000000000
xorl %eax, %eax
movq %rcx, (%rdx)
movl %eax, 0x8(%rdx)
movl %eax, 0x28(%rdx)
cmpq $0x0, 0x30(%rdx)
leaq 0x38(%rdx), %rdx
jne 0x12d46
jmp 0x12d5e
xorl %eax, %eax
popq %rcx
retq