// File: /workspace/github_c_makefile_star2_O0/rpeepz[P]ft_ssl/libft/srcs/ft_printf/convert_i.c
// Function: right_justify
static	int		right_justify(t_mods mod, char *num, int nbyte, int neg)
{
	int		len;

	if ((len = ft_strlen(num)) && neg == 1)
	{
		if (mod.fl.fzero && mod.prcsn < 0 && mod.width > len)
			nbyte += (int)write(1, "-", 1);
		nbyte = pad_width(mod, len, nbyte, neg);
		if (!mod.fl.fzero || mod.prcsn > 0 || !nbyte)
			nbyte += (int)write(1, "-", 1);
	}
	else if (neg == 0)
	{
		if (mod.fl.fplus && mod.fl.fzero && mod.prcsn < 0 &&
			mod.width > len && (mod.fl.space = -1))
			nbyte += (int)write(1, "+", 1);
		nbyte = pad_width(mod, len, nbyte, mod.fl.fplus);
		if ((mod.fl.fplus && mod.fl.space != -1))
			nbyte += (int)write(1, "+", 1);
		if (!mod.fl.fplus && mod.fl.space && !nbyte)
			nbyte += (int)write(1, " ", 1);
	}
	if (mod.prcsn > len)
		while ((mod.prcsn--) - len > 0)
			nbyte += (int)write(1, "0", 1);
	return (nbyte += (int)write(1, num, len));
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
leaq 0x10(%rbp), %rax
movq %rax, -0x20(%rbp)
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movl %edx, -0x10(%rbp)
movq -0x8(%rbp), %rdi
callq 0xbf10
movl %eax, -0x14(%rbp)
cmpl $0x0, %eax
je 0xe0d9
cmpl $0x1, -0x10(%rbp)
jne 0xe0d9
movq -0x20(%rbp), %rax
cmpl $0x0, 0x10(%rax)
je 0xe065
movq -0x20(%rbp), %rax
cmpl $0x0, 0x18(%rax)
jge 0xe065
movq -0x20(%rbp), %rax
movl 0x14(%rax), %eax
cmpl -0x14(%rbp), %eax
jle 0xe065
movl $0x1, %edi
leaq 0x6402(%rip), %rsi      # 0x14457
movl $0x1, %edx
callq 0x1050
addl -0xc(%rbp), %eax
movl %eax, -0xc(%rbp)
movq -0x20(%rbp), %rax
movl -0x14(%rbp), %edi
movl -0xc(%rbp), %esi
movl -0x10(%rbp), %edx
movq (%rax), %rcx
movq %rcx, (%rsp)
movq 0x8(%rax), %rcx
movq %rcx, 0x8(%rsp)
movq 0x10(%rax), %rcx
movq %rcx, 0x10(%rsp)
movq 0x18(%rax), %rax
movq %rax, 0x18(%rsp)
callq 0xe240
movl %eax, %ecx
movq -0x20(%rbp), %rax
movl %ecx, -0xc(%rbp)
cmpl $0x0, 0x10(%rax)
je 0xe0b8
movq -0x20(%rbp), %rax
cmpl $0x0, 0x18(%rax)
jg 0xe0b8
cmpl $0x0, -0xc(%rbp)
jne 0xe0d4
movl $0x1, %edi
leaq 0x6393(%rip), %rsi      # 0x14457
movl $0x1, %edx
callq 0x1050
addl -0xc(%rbp), %eax
movl %eax, -0xc(%rbp)
jmp 0xe1dc
cmpl $0x0, -0x10(%rbp)
jne 0xe1da
movq -0x20(%rbp), %rax
cmpl $0x0, 0xc(%rax)
je 0xe13b
movq -0x20(%rbp), %rax
cmpl $0x0, 0x10(%rax)
je 0xe13b
movq -0x20(%rbp), %rax
cmpl $0x0, 0x18(%rax)
jge 0xe13b
movq -0x20(%rbp), %rax
movl 0x14(%rax), %eax
cmpl -0x14(%rbp), %eax
jle 0xe13b
movq -0x20(%rbp), %rax
movl $0xffffffff, (%rax)     # imm = 0xFFFFFFFF
movb $0x1, %al
testb $0x1, %al
jne 0xe11f
jmp 0xe13b
movl $0x1, %edi
leaq 0x632e(%rip), %rsi      # 0x14459
movl $0x1, %edx
callq 0x1050
addl -0xc(%rbp), %eax
movl %eax, -0xc(%rbp)
movq -0x20(%rbp), %rax
movl -0x14(%rbp), %edi
movl -0xc(%rbp), %esi
movl 0xc(%rax), %edx
movq (%rax), %rcx
movq %rcx, (%rsp)
movq 0x8(%rax), %rcx
movq %rcx, 0x8(%rsp)
movq 0x10(%rax), %rcx
movq %rcx, 0x10(%rsp)
movq 0x18(%rax), %rax
movq %rax, 0x18(%rsp)
callq 0xe240
movl %eax, %ecx
movq -0x20(%rbp), %rax
movl %ecx, -0xc(%rbp)
cmpl $0x0, 0xc(%rax)
je 0xe1a3
movq -0x20(%rbp), %rax
cmpl $-0x1, (%rax)
je 0xe1a3
movl $0x1, %edi
leaq 0x62c6(%rip), %rsi      # 0x14459
movl $0x1, %edx
callq 0x1050
addl -0xc(%rbp), %eax
movl %eax, -0xc(%rbp)
movq -0x20(%rbp), %rax
cmpl $0x0, 0xc(%rax)
jne 0xe1d8
movq -0x20(%rbp), %rax
cmpl $0x0, (%rax)
je 0xe1d8
cmpl $0x0, -0xc(%rbp)
jne 0xe1d8
movl $0x1, %edi
leaq 0x611a(%rip), %rsi      # 0x142e2
movl $0x1, %edx
callq 0x1050
addl -0xc(%rbp), %eax
movl %eax, -0xc(%rbp)
jmp 0xe1da
jmp 0xe1dc
movq -0x20(%rbp), %rax
movl 0x18(%rax), %eax
cmpl -0x14(%rbp), %eax
jle 0xe221
jmp 0xe1ea
movq -0x20(%rbp), %rcx
movl 0x18(%rcx), %eax
movl %eax, %edx
addl $-0x1, %edx
movl %edx, 0x18(%rcx)
subl -0x14(%rbp), %eax
cmpl $0x0, %eax
jle 0xe21f
movl $0x1, %edi
leaq 0x5b58(%rip), %rsi      # 0x13d65
movl $0x1, %edx
callq 0x1050
addl -0xc(%rbp), %eax
movl %eax, -0xc(%rbp)
jmp 0xe1ea
jmp 0xe221
movq -0x8(%rbp), %rsi
movslq -0x14(%rbp), %rdx
movl $0x1, %edi
callq 0x1050
addl -0xc(%rbp), %eax
movl %eax, -0xc(%rbp)
addq $0x40, %rsp
popq %rbp
retq
nop