// File: /workspace/github_c_makefile_star2_O2/cglindkamp[P]dfm/src/dirmodel.c
// Function: dirmodel_notify_flush
int dirmodel_notify_flush(struct dirmodel *model)
{
	int ret = 0;
	size_t length = list_length(model->addchange_queue);
	for(size_t i = 0; i < length; i++) {
		ret = dirmodel_notify_file_added_or_changed_real(model, list_get_item(model->addchange_queue, i));
		if(ret == ENOMEM)
			break;
	}
	for(size_t i = length; i > 0; i--) {
		free(list_get_item(model->addchange_queue, i - 1));
		list_remove(model->addchange_queue, i - 1);
	}
	return ret == ENOMEM ? ENOMEM : 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rdi, %rbx
movq 0x38(%rdi), %rdi
callq 0x7515
movq %rax, %r14
leaq 0x48(%rbx), %r13
xorl %r15d, %r15d
leaq 0x8(%rsp), %rbp
movq %r13, 0x10(%rsp)
cmpq %r15, %r14
je 0x6668
movq 0x38(%rbx), %rdi
movq %r15, %rsi
callq 0x76e4
movq %rax, %r12
cmpb $0x1, 0x88(%rbx)
jne 0x6477
movq %r13, %rdi
movq %r12, %rsi
xorl %edx, %edx
xorl %ecx, %ecx
xorl %r8d, %r8d
callq 0x34d0
testl %eax, %eax
jne 0x6658
movq 0x40(%rbx), %rdi
callq 0x33f0
movq %rbp, %rdi
movl %eax, %esi
movq %r12, %rdx
callq 0x7312
movl %eax, %r12d
testl %eax, %eax
jne 0x6652
movq 0x28(%rbx), %rdi
movq 0x8(%rsp), %rdx
leaq 0x848(%rip), %rsi       # 0x6cf0
leaq 0x20(%rsp), %rcx
callq 0x774e
movq 0x8(%rsp), %rbp
movq 0x20(%rsp), %r13
movq 0x28(%rbx), %rdi
movq %r13, %rsi
testb %al, %al
je 0x656d
callq 0x76e4
movq %rax, %r12
movb 0xa8(%rax), %al
movb %al, 0xa8(%rbp)
cmpb $0x1, %al
jne 0x64f1
movq %rbx, %rdi
movq %r12, %rsi
movq %rbp, %rdx
callq 0x61f0
movq %rbx, %rdi
movq %r12, %rsi
movq %rbp, %rdx
callq 0x6357
movq 0x30(%rbx), %rdi
movq 0x90(%rbx), %rsi
movq %r12, %rdx
leaq 0x18(%rsp), %rcx
callq 0x774e
movq 0x30(%rbx), %rdi
movq 0x90(%rbx), %rsi
movq %rbp, %rdx
movq %rsp, %rcx
callq 0x774e
movq (%rsp), %rdx
movq 0x18(%rsp), %rsi
cmpq %rsi, %rdx
setne %al
leaq 0x1(%rsi), %rcx
cmpq %rcx, %rdx
setne %cl
testb %cl, %al
jne 0x65e2
movq 0x30(%rbx), %rdi
movq %rbp, %rdx
callq 0x7710
movq 0x18(%rsp), %rcx
movq %rbx, %rdi
pushq $0x2
popq %rsi
movq %rcx, %rdx
jmp 0x6606
movq %rbp, %rdx
callq 0x7581
testb %al, %al
je 0x6660
movq 0x30(%rbx), %rdi
movq 0x90(%rbx), %rsi
movq %rbp, %rdx
movq %rsp, %rcx
callq 0x774e
movq 0x30(%rbx), %rdi
movq (%rsp), %rsi
movq %rbp, %rdx
callq 0x7581
testb %al, %al
je 0x662e
testq %rbp, %rbp
je 0x65cd
leaq 0x40(%rbp), %rax
leaq 0xa0(%rbp), %rcx
cmpb $0x0, 0x8(%rbp)
cmovneq %rcx, %rax
movq (%rax), %rax
addq %rax, 0xb0(%rbx)
movq (%rsp), %rdx
xorl %r12d, %r12d
movq %rbx, %rdi
xorl %esi, %esi
xorl %ecx, %ecx
callq 0x7901
jmp 0x6648
cmpq %rdx, %rsi
jae 0x65ee
decq %rdx
movq %rdx, (%rsp)
movq 0x30(%rbx), %rdi
callq 0x75fc
movq (%rsp), %rdx
movq 0x18(%rsp), %rcx
movq %rbx, %rdi
pushq $0x2
popq %rsi
callq 0x7901
movq 0x28(%rbx), %rdi
movq %r13, %rsi
movq %rbp, %rdx
callq 0x7710
movq %r12, %rdi
callq 0x7463
movq 0x10(%rsp), %r13
leaq 0x8(%rsp), %rbp
jmp 0x6658
movq %rbp, %rdi
callq 0x7463
movq 0x28(%rbx), %rdi
movq %r13, %rsi
callq 0x7694
pushq $0xc
popq %rax
movl %eax, %r12d
movq 0x10(%rsp), %r13
leaq 0x8(%rsp), %rbp
cmpl $0xc, %r12d
je 0x6668
incq %r15
jmp 0x643c
movq %rbp, %rdi
callq 0x7463
leaq -0x1(%r14), %r12
cmpq $-0x1, %r12
je 0x6697
movq 0x38(%rbx), %rdi
movq %r12, %rsi
callq 0x76e4
movq %rax, %rdi
callq 0x3740
movq 0x38(%rbx), %rdi
movq %r12, %rsi
callq 0x7694
decq %r12
jmp 0x666c
xorl %ecx, %ecx
cmpq %r14, %r15
pushq $0xc
popq %rax
cmovael %ecx, %eax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq