// File: /workspace/github_c_makefile_star2_O3/dlbeer[P]ufat/main.c
// Function: cmd_chattr
static int cmd_chattr(struct ufat *uf, const struct options *opt)
{
	struct ufat_dirent ent;
	int err;
	int i;

	if (!opt->argc) {
		fprintf(stderr, "You must specify a file path\n");
		return -1;
	}

	if (require_file(uf, opt->argv[0], &ent) < 0)
		return -1;

	for (i = 1; i < opt->argc; i++)
		if (parse_attribute(opt->argv[i], &ent) < 0)
			return -1;

	err = ufat_update_attributes(uf, &ent);
	if (err < 0) {
		fprintf(stderr, "ufat_dir_update_attributes: %s\n",
			ufat_strerror(err));
		return -1;
	}

	return 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x98, %rsp
cmpl $0x0, 0x40(%rsi)
je 0x5fc8
movq %rsi, %r15
movq %rdi, %r14
movq 0x38(%rsi), %rax
movq (%rax), %rsi
leaq 0x8(%rsp), %rdx
callq 0x61cb
movl $0xffffffff, %ebx       # imm = 0xFFFFFFFF
testl %eax, %eax
js 0x5fd2
movq %r14, (%rsp)
movl 0x40(%r15), %eax
cmpl $0x2, %eax
jl 0x5f8d
movl $0x1, %r14d
leaq 0x50(%rsp), %r12
movq 0x38(%r15), %rcx
movq (%rcx,%r14,8), %rbp
movzbl (%rbp), %edx
cmpl $0x2b, %edx
je 0x5e05
cmpl $0x7e, %edx
je 0x5e05
cmpl $0x3d, %edx
jne 0x5e96
incq %rbp
xorl %ecx, %ecx
movzbl (%rbp), %esi
movl $0x20, %edi
cmpl $0x60, %esi
jg 0x5e29
cmpl $0x51, %esi
jg 0x5e52
cmpl $0x41, %esi
je 0x5e6c
cmpl $0x48, %esi
je 0x5e3c
jmp 0x5e73
cmpl $0x71, %esi
jg 0x5e43
cmpl $0x61, %esi
je 0x5e6c
cmpl $0x68, %esi
jne 0x5faa
movl $0x2, %edi
jmp 0x5e6c
cmpl $0x72, %esi
je 0x5e67
cmpl $0x73, %esi
je 0x5e60
jmp 0x5faa
cmpl $0x52, %esi
je 0x5e67
cmpl $0x53, %esi
jne 0x5faa
movl $0x4, %edi
jmp 0x5e6c
movl $0x1, %edi
orl %edi, %ecx
incq %rbp
jmp 0x5e0a
testl %esi, %esi
jne 0x5faa
cmpl $0x3d, %edx
je 0x5f40
cmpl $0x2b, %edx
jne 0x5f3a
orl 0x34(%rsp), %ecx
jmp 0x5f40
movl $0x40, %edx
movq %r12, %rdi
movq %rbp, %rsi
callq 0x1080
movb $0x0, 0x8f(%rsp)
movq %r12, %rdi
movl $0x3d, %esi
callq 0x10f0
testq %rax, %rax
je 0x5fe6
movq %rax, %r13
incq %r13
movb $0x0, (%rax)
movq %r12, %rdi
leaq 0x1d40(%rip), %rsi      # 0x7c17
callq 0x1040
testl %eax, %eax
je 0x5f46
movq %r12, %rdi
leaq 0x1d39(%rip), %rsi      # 0x7c23
callq 0x1040
testl %eax, %eax
je 0x5f50
movq %r12, %rdi
leaq 0x1d32(%rip), %rsi      # 0x7c2f
callq 0x1040
testl %eax, %eax
je 0x5f5a
movq %r12, %rdi
leaq 0x1d2b(%rip), %rsi      # 0x7c3b
callq 0x1040
testl %eax, %eax
je 0x5f69
movq %r12, %rdi
leaq 0x1d24(%rip), %rsi      # 0x7c47
callq 0x1040
testl %eax, %eax
jne 0x6003
movq %r13, %rdi
leaq 0x40(%rsp), %rsi
jmp 0x5f62
notl %ecx
andl 0x34(%rsp), %ecx
movl %ecx, 0x34(%rsp)
jmp 0x5f7e
movq %r13, %rdi
leaq 0x38(%rsp), %rsi
jmp 0x5f62
movq %r13, %rdi
leaq 0x3a(%rsp), %rsi
jmp 0x5f71
movq %r13, %rdi
leaq 0x3c(%rsp), %rsi
callq 0x62c2
jmp 0x5f76
movq %r13, %rdi
leaq 0x3e(%rsp), %rsi
callq 0x63d9
testl %eax, %eax
js 0x5fd2
movl 0x40(%r15), %eax
incq %r14
movslq %eax, %rcx
cmpq %rcx, %r14
jl 0x5de6
leaq 0x8(%rsp), %rsi
movq (%rsp), %rdi
callq 0x423e
xorl %ebx, %ebx
testl %eax, %eax
jns 0x5fd2
movl %eax, %edi
callq 0x1653
jmp 0x5fcd
movsbl %sil, %edx
movq 0x5043(%rip), %rax      # 0xaff8
movq (%rax), %rdi
leaq 0x1cab(%rip), %rsi      # 0x7c6a
xorl %eax, %eax
callq 0x1140
jmp 0x5fcd
callq 0x1679
movl $0xffffffff, %ebx       # imm = 0xFFFFFFFF
movl %ebx, %eax
addq $0x98, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq 0x500b(%rip), %rax      # 0xaff8
movq (%rax), %rdi
leaq 0x1bfb(%rip), %rsi      # 0x7bf2
movq %rbp, %rdx
xorl %eax, %eax
callq 0x1140
jmp 0x5fcd
movq 0x4fee(%rip), %rax      # 0xaff8
movq (%rax), %rdi
leaq 0x1c3f(%rip), %rsi      # 0x7c53
leaq 0x50(%rsp), %rdx
jmp 0x5ffa