// File: /workspace/github_c_makefile_star2_O1/neosploit[P]compiler/libfort/lib/fort.c
// Function: print_n_strings
FT_INTERNAL
int print_n_strings(f_conv_context_t *cntx, size_t n, const char *str)
{
    int cod_w;
    int raw_written;

    switch (cntx->b_type) {
        case CHAR_BUF:
            raw_written = snprint_n_strings(cntx, n, str);
            cod_w = raw_written;
            return cod_w;
#ifdef FT_HAVE_WCHAR
        case W_CHAR_BUF:
            cod_w = wsnprint_n_string(cntx->u.wbuf, cntx->raw_avail, n, str);
            if (cod_w < 0)
                return cod_w;
            raw_written = sizeof(wchar_t) * cod_w;

            cntx->u.buf += raw_written;
            cntx->raw_avail -= raw_written;
            return cod_w;
#endif /* FT_HAVE_WCHAR */
#ifdef FT_HAVE_UTF8
        case UTF8_BUF:
            /* Everying is very strange and differs with W_CHAR_BUF */
            raw_written = u8nprint_n_strings(cntx->u.buf, cntx->raw_avail, n, str);
            if (raw_written < 0) {
                fprintf(stderr, " raw_written = %d\n", raw_written);
                return raw_written;
            }

            cntx->u.buf += raw_written;
            cntx->raw_avail -= raw_written;
            return utf8len(str) * n;
#endif /* FT_HAVE_UTF8 */
        default:
            assert(0);
            return -1;
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x138, %rsp            # imm = 0x138
movq %rdx, %r13
movq %rdi, %rbx
movl 0x18(%rdi), %eax
cmpl $0x2, %eax
movq %rdx, -0x40(%rbp)
je 0x13e77
cmpl $0x1, %eax
je 0x13dea
movq %rsi, -0x30(%rbp)
testl %eax, %eax
jne 0x14069
movq (%rbx), %r12
movq 0x8(%rbx), %r15
movq %r13, %rdi
callq 0x70e0
movq %rax, %r14
movq -0x30(%rbp), %rcx
imulq %rcx, %r14
movl $0xffffffff, %r13d      # imm = 0xFFFFFFFF
cmpq %r15, %r14
jae 0x13f32
testq %rcx, %rcx
je 0x13f2f
cmpq $0x7fffffff, %r14       # imm = 0x7FFFFFFF
ja 0x13f32
movl $0x0, %r13d
testq %rax, %rax
je 0x13f32
leaq 0x704d(%rip), %rdx      # 0x1ade4
movq %r12, %rdi
movq %r15, %rsi
movl %r14d, %ecx
xorl %r8d, %r8d
xorl %eax, %eax
callq 0x7120
testl %eax, %eax
js 0x1405c
movq -0x40(%rbp), %r8
leaq 0x1(%r8), %rax
xorl %ecx, %ecx
movq -0x30(%rbp), %rdi
movb (%r8), %dl
testb %dl, %dl
je 0x13dda
movq %rax, %rsi
movb %dl, (%r12)
incq %r12
movb (%rsi), %dl
incq %rsi
testb %dl, %dl
jne 0x13dca
incq %rcx
cmpq %rdi, %rcx
jne 0x13dc0
movl %r14d, %r13d
jmp 0x13f32
movq %rsi, %r15
movq (%rbx), %r12
movq 0x8(%rbx), %rax
movq %rax, -0x30(%rbp)
movq %r13, %rdi
callq 0x70e0
cmpq $0x2, %rax
jb 0x13ef1
cmpb $0x0, (%r13)
sete %r14b
je 0x13ef9
js 0x13e34
leaq 0x1(%r13), %rdx
movb (%rdx), %cl
testb %cl, %cl
sete %r14b
je 0x13ef9
incq %rdx
testb %cl, %cl
jns 0x13e1f
movq %rax, -0x48(%rbp)
leaq -0x58(%rbp), %rsi
movq %r13, (%rsi)
leaq -0x50(%rbp), %rcx
movq $0x0, (%rcx)
leaq -0x160(%rbp), %rdi
movl $0x40, %edx
callq 0x71e0
movl $0xffffffff, %r13d      # imm = 0xFFFFFFFF
cmpq $0x1, %rax
jbe 0x13f43
movq %r15, %rdx
movq -0x48(%rbp), %rax
jmp 0x13fa1
movq (%rbx), %r14
movq %rbx, -0x38(%rbp)
movq 0x8(%rbx), %rbx
movq %r13, %rdi
movq %rsi, -0x30(%rbp)
callq 0xdc5a
movq -0x30(%rbp), %rcx
movq %rax, %r12
decq %r12
movq %r12, %r15
imulq %rcx, %r15
movl $0xffffffff, %r13d      # imm = 0xFFFFFFFF
cmpq %rbx, %r15
jae 0x13f04
testq %rcx, %rcx
je 0x13f01
cmpq $0x7fffffff, %r15       # imm = 0x7FFFFFFF
movq -0x38(%rbp), %rdx
ja 0x13f08
movl $0x0, %r13d
testq %r12, %r12
je 0x13f08
movq %rcx, %r13
movq -0x40(%rbp), %rbx
movq %r14, %rdi
movq %rbx, %rsi
movq %r12, %rdx
callq 0x71f0
addq %r12, %r14
decq %r13
jne 0x13ece
movb $0x0, (%r14)
movl %r15d, %r13d
movq -0x30(%rbp), %rcx
jmp 0x13f04
movq %r15, %rdx
jmp 0x13faa
movq %r15, %rdx
jmp 0x13fa1
xorl %r13d, %r13d
movq -0x38(%rbp), %rdx
testl %r13d, %r13d
js 0x13f72
movl %r13d, %eax
addq %rax, (%rdx)
subq %rax, 0x8(%rdx)
movq -0x40(%rbp), %rdi
movq %rcx, %rbx
callq 0xdc6c
movq %rax, %r13
imull %ebx, %r13d
jmp 0x14047
xorl %r13d, %r13d
testl %r13d, %r13d
js 0x14047
movl %r13d, %eax
jmp 0x14040
movl $0x0, -0x160(%rbp,%rax,4)
movq %r15, %rdx
testq %r15, %r15
je 0x13f92
movl -0x160(%rbp), %esi
movq %rdx, %rcx
movq -0x48(%rbp), %rax
movl %esi, (%r12)
addq $0x4, %r12
decq %rcx
jne 0x13f63
jmp 0x13f96
movq 0xd077(%rip), %rax      # 0x20ff0
movq (%rax), %rdi
leaq 0x6e10(%rip), %rsi      # 0x1ad93
movl %r13d, %edx
xorl %eax, %eax
callq 0x7190
jmp 0x14047
movq -0x48(%rbp), %rax
movl $0x0, (%r12,%rdx,4)
movl %edx, %r13d
testb %r14b, %r14b
je 0x14031
movq %rax, %r14
imulq %rdx, %r14
movl $0xffffffff, %r13d      # imm = 0xFFFFFFFF
cmpq -0x30(%rbp), %r14
jae 0x14031
testq %rdx, %rdx
je 0x1402e
cmpq $0x7fffffff, %r14       # imm = 0x7FFFFFFF
ja 0x14031
movl $0x0, %r13d
testq %rax, %rax
je 0x14031
leaq 0x7473(%rip), %rdx      # 0x1b450
movq %r12, %rdi
movq -0x30(%rbp), %rsi
movl %r14d, %ecx
xorl %r8d, %r8d
xorl %eax, %eax
callq 0x71a0
testl %eax, %eax
js 0x14064
movq -0x40(%rbp), %rdi
leaq 0x1(%rdi), %rax
xorl %ecx, %ecx
movb (%rdi), %sil
testb %sil, %sil
je 0x14021
movq %rax, %rdx
movsbl %sil, %esi
movl %esi, (%r12)
addq $0x4, %r12
movb (%rdx), %sil
incq %rdx
testb %sil, %sil
jne 0x1400a
incq %rcx
cmpq %r15, %rcx
jne 0x13fff
movl %r14d, %r13d
jmp 0x14031
xorl %r13d, %r13d
testl %r13d, %r13d
js 0x14047
leal (,%r13,4), %eax
cltq
addq %rax, (%rbx)
subq %rax, 0x8(%rbx)
movl %r13d, %eax
addq $0x138, %rsp            # imm = 0x138
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movl %eax, %r13d
jmp 0x13f32
movl %eax, %r13d
jmp 0x14031
leaq 0x6300(%rip), %rdi      # 0x1a370
leaq 0x5a0f(%rip), %rsi      # 0x19a86
leaq 0x6d28(%rip), %rcx      # 0x1ada6
movl $0xfef, %edx            # imm = 0xFEF
callq 0x7130